Salome HOME
copy tag mergefrom_BR_V0_1_CC_Salome_04oct07
[modules/yacs.git] / src / wrappergen / src / compile_HXX2SALOME_GENERIC_CLASS_NAME.sh
diff --git a/src/wrappergen/src/compile_HXX2SALOME_GENERIC_CLASS_NAME.sh b/src/wrappergen/src/compile_HXX2SALOME_GENERIC_CLASS_NAME.sh
new file mode 100644 (file)
index 0000000..ca5df9e
--- /dev/null
@@ -0,0 +1,35 @@
+#! /bin/bash
+
+export BASE=PREFIX/tests
+export COMP_NAME=HXX2SALOME_GENERIC_CLASS_NAME
+export COMP_BASE=${BASE}/${COMP_NAME}
+
+cd ${COMP_BASE}
+export HXX2SALOME_ROOT_DIR=PREFIX/bin/HXX2SALOME_Test
+
+if [ ! -d ${COMP_NAME}_SRC ] ; then
+   ${HXX2SALOME_ROOT_DIR}/hxx2salome -q -q \
+         ${BASE} \
+         ${COMP_NAME}.hxx \
+         lib${COMP_NAME}.so \
+         ${BASE}
+fi
+
+cd ${COMP_BASE}
+if [ ! -f ${COMP_NAME}_SRC/configure ] ; then 
+   cd ${COMP_NAME}_SRC && ./build_configure
+fi
+
+cd ${COMP_BASE}
+source ${COMP_NAME}_SRC/env_${COMP_NAME}.sh
+
+if [ ! -f ${COMP_NAME}_BUILD/config.log ] ; then 
+   cd ${COMP_NAME}_BUILD && \
+   ../${COMP_NAME}_SRC/configure \
+          --prefix=${COMP_BASE}/${COMP_NAME}_INSTALL 
+fi
+
+cd ${COMP_BASE}/${COMP_NAME}_BUILD
+make && make install
+
+