4 # Tool for updating list of .in file for the SALOME project
5 # and regenerating configure script
7 # Author : Marc Tajchman - CEA
9 # Modified by : Alexander BORODIN (OCN) - autotools usage
12 # 13/03/2007: Alexander BORODIN - OCN
13 # Reorganization for usage of autotools
16 CONF_DIR=`echo $0 | sed -e "s,[^/]*$,,;s,/$,,;s,^$,.,"`
19 ########################################################################
20 # Test if the KERNEL_ROOT_DIR is set correctly
21 if test ! -d "${KERNEL_ROOT_DIR}"; then
22 echo "failed : KERNEL_ROOT_DIR variable is not correct !"
26 # Test if the KERNEL_SRC is set correctly
28 #if test ! -d "${KERNEL_SRC}"; then
29 # echo "failed : KERNEL_SRC variable is not correct !"
36 -with-ihm | --with-ihm)
39 -without-ihm | --without-ihm | -with-ihm=no | --with-ihm=no)
45 ########################################################################
46 # Test if the GUI_ROOT_DIR is set correctly
47 if test ${GEOM_WITH_GUI} = yes; then
48 if test ! -d "${GUI_ROOT_DIR}"; then
49 echo "failed : GUI_ROOT_DIR variable is not correct !"
57 #######################################################################
58 # Update configure.ac script: to set NETGENPLUGIN_WITH_GUI variable
59 sed -e s/GEOM_WITH_GUI=[a-z]*/GEOM_WITH_GUI=${GEOM_WITH_GUI}/g configure.ac > configure.tmp
60 mv -f configure.tmp configure.ac
62 mkdir -p salome_adm/unix/config_files
63 #cp -f ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files/* salome_adm/unix/config_files
64 #cp -f ${KERNEL_ROOT_DIR}/salome_adm/unix/pythonbe.py salome_adm/unix
66 cp -f ${KERNEL_ROOT_DIR}/salome_adm/unix/SALOMEconfig.h.in salome_adm/unix
68 #cp -f ${GUI_ROOT_DIR}/adm_local/unix/config_files/* salome_adm/unix/config_files
70 # remove KERNEL deprecated configure files
71 #for deprecated in ac_cc_warnings.m4 ac_cxx_partial_specialization.m4 \
72 # check_mico.m4 config.guess ltmain.sh ac_cxx_bool.m4 ltconfig ac_cxx_typename.m4 \
73 # check_pthreads.m4 config.sub libtool.m4 ac_cxx_mutable.m4 missing
75 # rm -f salome_adm/unix/config_files/${deprecated}
79 # ____________________________________________________________________
80 # aclocal creates the aclocal.m4 file from the standard macro and the
81 # custom macro embedded in the directory salome_adm/unix/config_files
82 # and KERNEL config_files directory.
85 # autom4te.cache (directory)
86 echo "====================================================== aclocal"
88 if test ${GEOM_WITH_GUI} = yes; then
89 aclocal -I adm_local/unix/config_files \
90 -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files \
91 -I ${GUI_ROOT_DIR}/adm_local/unix/config_files || exit 1
93 aclocal -I adm_local/unix/config_files \
94 -I ${KERNEL_ROOT_DIR}/salome_adm/unix/config_files || exit 1
97 # ____________________________________________________________________
98 # libtoolize creates some configuration files (ltmain.sh,
99 # config.guess and config.sub). It only depends on the libtool
100 # version. The files are created in the directory specified with the
101 # AC_CONFIG_AUX_DIR(<mydir>) tag (see configure.ac).
103 # salome_adm/unix/config_files/config.guess
104 # salome_adm/unix/config_files/config.sub
105 # salome_adm/unix/config_files/ltmain.sh
106 #echo "====================================================== libtoolize"
108 libtoolize --force --copy --automake || exit 1
110 # ____________________________________________________________________
111 # autoconf creates the configure script from the file configure.ac (or
112 # configure.in if configure.ac doesn't exist)
115 echo "====================================================== autoconf"
119 # ____________________________________________________________________
120 # automake creates some scripts used in building process
121 # (install-sh, missing, ...). It only depends on the automake
122 # version. The files are created in the directory specified with the
123 # AC_CONFIG_AUX_DIR(<mydir>) tag (see configure.ac). This step also
124 # creates the Makefile.in files from the Makefile.am files.
126 # salome_adm/unix/config_files/compile
127 # salome_adm/unix/config_files/depcomp
128 # salome_adm/unix/config_files/install-sh
129 # salome_adm/unix/config_files/missing
130 # salome_adm/unix/config_files/py-compile
131 # Makefile.in (from Makefile.am)
132 echo "====================================================== automake"
134 automake --copy --gnu --add-missing