To compile the java interface under linux 64 bits platforms
Pierre Marechal [Tue, 13 Jun 2006 14:00:55 +0000 (14:00 +0000)]
scilab/config/Makefile.linux64 [new file with mode: 0644]
scilab/configure
scilab/configure.in
scilab/routines/Javasci/Makefile.linux64 [new file with mode: 0644]

diff --git a/scilab/config/Makefile.linux64 b/scilab/config/Makefile.linux64
new file mode 100644 (file)
index 0000000..03919cc
--- /dev/null
@@ -0,0 +1,22 @@
+# Copyright INRIA
+
+FFLAGS = $(FC_OPTIONS)
+
+bin/scilex: scilex-lib 
+       @x=1;if test -f $@; then  \
+               x=`find $(MAINSCI) $(DEFAULTS) $(LIBR)  \( -name '*.a' -o -name '*.o' \) \
+               -newer $@ -print | wc -l `; \
+       fi;\
+       if test $$x -ne 0; then \
+               $(RM) $@; \
+               echo "linking"; \
+               $(FC) $(FFLAGS) -o $@ $(MAINSCI) $(DEFAULTS) $(FC_LDFLAGS) $(LIBR)\
+                       $(TCLTK_LIBS) $(XLIBS) $(TERMCAPLIB); \
+       else \
+               echo bin/scilex is up to date ; \
+       fi
+
+
+show   :
+       @echo $(FC) $(FFLAGS) -o $@ $(MAINSCI) $(DEFAULTS) $(FC_LDFLAGS) $(LIBR)\
+               $(TCLTK_LIBS) $(XLIBS) $(TERMCAPLIB);
index 14368a2..474eb05 100755 (executable)
                GCC=yes
                CC=gcc
                # CC_PLAT_OPTIONS is optional, and is used to add CPU specific code generation tuning for Athlon64 presumably Opteron could benefit too but these are not optimized for the Opteron
-               CC_PLAT_OPTIONS='-march=athlon64 -mfpmath=sse -msse2 -m3dnow -m64 '
-               CC_OPTIONS="-O2 -DNDEBUG -Dlinux  -DNARROWPROTO $CC_PLAT_OPTIONS"
+               CC_PLAT_OPTIONS='-march=athlon64 -mfpmath=sse -msse2 -m3dnow -m64'
+
+               CC_PICFLAGS='-fPIC'
+               FC_PICFLAGS='-fPIC'
+
+               CC_OPTIONS="-O2 -DNDEBUG -Dlinux  -DNARROWPROTO $CC_PLAT_OPTIONS $CC_PICFLAGS "
                CC_LDFLAGS=$LIEEELIB
-               CC_PICFLAGS=-fPIC
+
                if test "$enable_debug" = yes; then
-                       # CC_PLAT_OPTIONS is optional, and is used to add CPU specific code generation tuning for Athlon64 presumably Opteron could benefit too but these are not optimized for the Opteron
-                       CC_PLAT_OPTIONS='-march=athlon64 -mfpmath=sse -msse2 -m3dnow -m64 '
-                       CC_OPTIONS="-g -Wall -Dlinux -DNARROWPROTO $CC_PLAT_OPTIONS"
+                       CC_OPTIONS="-g -Wall -Dlinux -DNARROWPROTO $CC_PLAT_OPTIONS $CC_PICFLAGS "
                fi
                # find Fortran compiler
                # g77 already asked and found: good
                        FC=g77
                        FC_PICFLAGS=-fPIC
                        if test "$enable_debug" = yes; then
-                               FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        else
-                               FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        fi
                elif test "$WITH_GFORTRAN" = yes;then
                        FC=gfortran
                        if test "$enable_debug" = yes; then
-                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0="-ff2c"
+                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                        else
-                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0="-ff2c"
+                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                        fi
-                       FC_PICFLAGS=-fPIC
                        cat >>confdefs.h <<\_ACEOF
 #define G95_FORTRAN 1
 _ACEOF
@@ -20808,11 +20809,11 @@ echo "$as_me: error: Unable to configure: f2c compiler not found" >&2;}
                        # script shell f77 have bugs, get ours
                        FC='${SCIDIR}/bin/f77-linux'
                        if test "$enable_debug" = yes; then
-                               FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        else
-                               FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        fi
                else
                        # first find g77
                                FC_PICFLAGS=-fPIC
                                if test "$enable_debug" = yes; then
                                        FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                                       FC_OPTIONS_O0=""
+                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                else
                                        FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                                       FC_OPTIONS_O0=""
+                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                fi
                        else
                                # Extract the first word of "gfortran", so it can be a program name with args.
 _ACEOF
 
                                        if test "$enable_debug" = yes; then
-                                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS"
-                                               FC_OPTIONS_O0="-ff2c"
+                                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                                        else
-                                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS"
-                                               FC_OPTIONS_O0="-ff2c"
+                                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                                        fi
                                else
                                        # Extract the first word of "f95", so it can be a program name with args.
 _ACEOF
 
                                                if test "$enable_debug" = yes; then
-                                                       FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                                                       FC_OPTIONS_O0=""
+                                                       FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                                else
-                                                       FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                                                       FC_OPTIONS_O0=""
+                                                       FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS "
                                                fi
                                        else
                                                # otherwise find f2c
                                                        # script shell f77 have bugs, get ours
                                                        FC='${SCIDIR}/bin/f77-linux'
                                                        if test "$enable_debug" = yes; then
-                                                               FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                                                               FC_OPTIONS_O0=""
+                                                               FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                                        else
-                                                               FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                                                               FC_OPTIONS_O0=""
+                                                               FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                                        fi
                                                else
                                                        { { echo "$as_me:$LINENO: error: Unable to configure: no Fortran compiler found" >&5
@@ -21023,9 +21024,9 @@ echo "$as_me: error: Unable to configure: no Fortran compiler found" >&2;}
                fi
                FC_LDFLAGS="$LIEEELIB -ldl -rdynamic -Wl,-relax "
                LD=ld
-               LD_LDFLAGS="$LIEEELIB  -Wl,-relax "
+               LD_LDFLAGS="$LIEEELIB -Wl,-relax "
        fi
-       MAKEFILE_TARGET=Makefile.linux
+       MAKEFILE_TARGET=Makefile.linux64
        ;;
 # Linux ELF: all standard distributions
 i*86-*-linux-gnu | *-pc-linux-gnu )
@@ -22391,7 +22392,7 @@ _ACEOF
 # flags.
 ac_save_FFLAGS=$FFLAGS
 FFLAGS="$FFLAGS $ac_verb"
-(eval echo $as_me:22394: \"$ac_link\") >&5
+(eval echo $as_me:22395: \"$ac_link\") >&5
 ac_f77_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'`
 echo "$ac_f77_v_output" >&5
 FFLAGS=$ac_save_FFLAGS
@@ -22469,7 +22470,7 @@ _ACEOF
 # flags.
 ac_save_FFLAGS=$FFLAGS
 FFLAGS="$FFLAGS $ac_cv_prog_f77_v"
-(eval echo $as_me:22472: \"$ac_link\") >&5
+(eval echo $as_me:22473: \"$ac_link\") >&5
 ac_f77_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'`
 echo "$ac_f77_v_output" >&5
 FFLAGS=$ac_save_FFLAGS
@@ -23679,7 +23680,7 @@ fi
 
 
 # Provide some information about the compiler.
-echo "$as_me:23682:" \
+echo "$as_me:23683:" \
      "checking for Fortran 77 compiler version" >&5
 ac_compiler=`set X $ac_compile; echo $2`
 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
@@ -23874,7 +23875,7 @@ _ACEOF
 # flags.
 ac_save_FFLAGS=$FFLAGS
 FFLAGS="$FFLAGS $ac_verb"
-(eval echo $as_me:23877: \"$ac_link\") >&5
+(eval echo $as_me:23878: \"$ac_link\") >&5
 ac_f77_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'`
 echo "$ac_f77_v_output" >&5
 FFLAGS=$ac_save_FFLAGS
@@ -23952,7 +23953,7 @@ _ACEOF
 # flags.
 ac_save_FFLAGS=$FFLAGS
 FFLAGS="$FFLAGS $ac_cv_prog_f77_v"
-(eval echo $as_me:23955: \"$ac_link\") >&5
+(eval echo $as_me:23956: \"$ac_link\") >&5
 ac_f77_v_output=`eval $ac_link 5>&1 2>&1 | grep -v 'Driving:'`
 echo "$ac_f77_v_output" >&5
 FFLAGS=$ac_save_FFLAGS
@@ -27683,7 +27684,7 @@ CPPFLAGS="$CPPFLAGS -I$CHK_TCL_INCLUDE_PATH"
 echo "$as_me:$LINENO: checking if tcl is version $CHK_TCL_MAJOR.$CHK_TCL_MINOR or later" >&5
 echo $ECHO_N "checking if tcl is version $CHK_TCL_MAJOR.$CHK_TCL_MINOR or later... $ECHO_C" >&6
 cat > conftest.$ac_ext <<EOF
-#line 27686 "configure"
+#line 27687 "configure"
 #include "confdefs.h"
 
 #include "$CHK_TCL_INCLUDE_PATH/$CHK_TCL_INC_NAME"
@@ -28001,7 +28002,7 @@ CPPFLAGS="$CPPFLAGS $TCL_INC_PATH -I$CHK_TK_INCLUDE_PATH $X_CFLAGS"
 echo "$as_me:$LINENO: checking if tk is version $CHK_TK_MAJOR.$CHK_TK_MINOR or later" >&5
 echo $ECHO_N "checking if tk is version $CHK_TK_MAJOR.$CHK_TK_MINOR or later... $ECHO_C" >&6
 cat > conftest.$ac_ext <<EOF
-#line 28004 "configure"
+#line 28005 "configure"
 #include "confdefs.h"
 
 #include "$CHK_TK_INCLUDE_PATH/$CHK_TK_INC_NAME"
index a5c47dc..8d0ebf1 100644 (file)
@@ -558,14 +558,16 @@ x86_64-*-linux-gnu)
                GCC=yes
                CC=gcc
                # CC_PLAT_OPTIONS is optional, and is used to add CPU specific code generation tuning for Athlon64 presumably Opteron could benefit too but these are not optimized for the Opteron
-               CC_PLAT_OPTIONS='-march=athlon64 -mfpmath=sse -msse2 -m3dnow -m64 '
-               CC_OPTIONS="-O2 -DNDEBUG -Dlinux  -DNARROWPROTO $CC_PLAT_OPTIONS"
+               CC_PLAT_OPTIONS='-march=athlon64 -mfpmath=sse -msse2 -m3dnow -m64'
+               
+               CC_PICFLAGS='-fPIC'
+               FC_PICFLAGS='-fPIC'
+               
+               CC_OPTIONS="-O2 -DNDEBUG -Dlinux  -DNARROWPROTO $CC_PLAT_OPTIONS $CC_PICFLAGS "
                CC_LDFLAGS=$LIEEELIB
-               CC_PICFLAGS=-fPIC
+
                if test "$enable_debug" = yes; then
-                       # CC_PLAT_OPTIONS is optional, and is used to add CPU specific code generation tuning for Athlon64 presumably Opteron could benefit too but these are not optimized for the Opteron
-                       CC_PLAT_OPTIONS='-march=athlon64 -mfpmath=sse -msse2 -m3dnow -m64 '
-                       CC_OPTIONS="-g -Wall -Dlinux -DNARROWPROTO $CC_PLAT_OPTIONS"
+                       CC_OPTIONS="-g -Wall -Dlinux -DNARROWPROTO $CC_PLAT_OPTIONS $CC_PICFLAGS "
                fi
                # find Fortran compiler
                # g77 already asked and found: good
@@ -573,22 +575,21 @@ x86_64-*-linux-gnu)
                        FC=g77
                        FC_PICFLAGS=-fPIC
                        if test "$enable_debug" = yes; then
-                               FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        else
-                               FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        fi
                elif test "$WITH_GFORTRAN" = yes;then
                        FC=gfortran
                        if test "$enable_debug" = yes; then
-                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0="-ff2c"
+                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                        else
-                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0="-ff2c"
+                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                        fi
-                       FC_PICFLAGS=-fPIC
                        AC_DEFINE(G95_FORTRAN)
                # option with-f2c
                elif test "$with_f2c" = yes; then
@@ -599,11 +600,11 @@ x86_64-*-linux-gnu)
                        # script shell f77 have bugs, get ours
                        FC='${SCIDIR}/bin/f77-linux'
                        if test "$enable_debug" = yes; then
-                               FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        else
-                               FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                               FC_OPTIONS_O0=""
+                               FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                        fi
                else
                        # first find g77
@@ -613,10 +614,10 @@ x86_64-*-linux-gnu)
                                FC_PICFLAGS=-fPIC
                                if test "$enable_debug" = yes; then
                                        FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                                       FC_OPTIONS_O0=""
+                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                else
                                        FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                                       FC_OPTIONS_O0=""
+                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                fi
                        else
                                AC_CHECK_PROG(WITH_GFORTRAN,gfortran,yes,no)
@@ -625,11 +626,11 @@ x86_64-*-linux-gnu)
                                        FC_PICFLAGS=-fPIC
                                        AC_DEFINE(G95_FORTRAN)
                                        if test "$enable_debug" = yes; then
-                                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS"
-                                               FC_OPTIONS_O0="-ff2c"
+                                               FC_OPTIONS="-g -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                                        else
-                                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS"
-                                               FC_OPTIONS_O0="-ff2c"
+                                               FC_OPTIONS="-O -ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                               FC_OPTIONS_O0="-ff2c $CC_PLAT_OPTIONS $FC_PICFLAGS"
                                        fi
                                else
                                        AC_CHECK_PROG(WITH_F95,f95,yes,no)
@@ -638,11 +639,11 @@ x86_64-*-linux-gnu)
                                                FC_PICFLAGS=-fPIC
                                                AC_DEFINE(F95_FORTRAN)
                                                if test "$enable_debug" = yes; then
-                                                       FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                                                       FC_OPTIONS_O0=""
+                                                       FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                                else
-                                                       FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                                                       FC_OPTIONS_O0=""
+                                                       FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                       FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS "
                                                fi
                                        else
                                                # otherwise find f2c
@@ -651,11 +652,11 @@ x86_64-*-linux-gnu)
                                                        # script shell f77 have bugs, get ours
                                                        FC='${SCIDIR}/bin/f77-linux'
                                                        if test "$enable_debug" = yes; then
-                                                               FC_OPTIONS="-g $CC_PLAT_OPTIONS"
-                                                               FC_OPTIONS_O0=""
+                                                               FC_OPTIONS="-g $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                                        else
-                                                               FC_OPTIONS="-O $CC_PLAT_OPTIONS"
-                                                               FC_OPTIONS_O0=""
+                                                               FC_OPTIONS="-O $CC_PLAT_OPTIONS $FC_PICFLAGS"
+                                                               FC_OPTIONS_O0="$CC_PLAT_OPTIONS $FC_PICFLAGS"
                                                        fi
                                                else
                                                        AC_MSG_ERROR([Unable to configure: no Fortran compiler found])    
@@ -666,9 +667,9 @@ x86_64-*-linux-gnu)
                fi
                FC_LDFLAGS="$LIEEELIB -ldl -rdynamic -Wl,-relax "
                LD=ld
-               LD_LDFLAGS="$LIEEELIB  -Wl,-relax "
+               LD_LDFLAGS="$LIEEELIB -Wl,-relax "
        fi
-       MAKEFILE_TARGET=Makefile.linux
+       MAKEFILE_TARGET=Makefile.linux64
        ;;
 # Linux ELF: all standard distributions
 i*86-*-linux-gnu | *-pc-linux-gnu )
diff --git a/scilab/routines/Javasci/Makefile.linux64 b/scilab/routines/Javasci/Makefile.linux64
new file mode 100644 (file)
index 0000000..4473b5f
--- /dev/null
@@ -0,0 +1,7 @@
+all1:: $(LIBRARY)
+# options compilation a modifier sous hp & solaris
+$(LIBRARY): $(OBJS)
+       @echo Creation of $(LIBRARY)
+       @$(RM) $@;
+       @echo "linking";
+       @$(FC) -shared -g -o $@ $(OBJS) $(DEFAULTS) $(LIBR) $(TCLTK_LIBS) $(XLIBS) $(TERMCAPLIB);