From 51f3e0049f3d79150e69141679fc9acabc0facfe Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 7 Jul 2009 13:19:24 +0200 Subject: Solaris 10 build script fixes by Toby Thain. Added build scripts for 32 bit x86 architecture on Solaris. Renamed some scripts for consistency. Changed to dynamic linking of libgcc. BUILD/compile-solaris-amd64: Changed to dynamic linking of libgcc. The -static-libgcc was a legacy of the original build scripts. -R (analogous to -L link time search path) is a Solaris mechanism to ensure a needed lib directory is searched at runtime. In Solaris 10, gcc comes bundled, under /usr/sfw, allowing to use it without creating dependency problems. This allows eg. benefiting from ordinary system patch maintenance. BUILD/compile-solaris-amd64-debug: Changed to dynamic linking of libgcc. The -static-libgcc was a legacy of the original build scripts. -R (analogous to -L link time search path) is a Solaris mechanism to ensure a needed lib directory is searched at runtime. In Solaris 10, gcc comes bundled, under /usr/sfw, allowing to use it without creating dependency problems. This allows eg. benefiting from ordinary system patch maintenance. --- BUILD/compile-solaris-amd64 | 2 +- BUILD/compile-solaris-amd64-debug | 2 +- BUILD/compile-solaris-amd64-debug-forte | 27 +++++++++++++++++++++++++++ BUILD/compile-solaris-amd64-forte-debug | 27 --------------------------- BUILD/compile-solaris-x86-32 | 11 +++++++++++ BUILD/compile-solaris-x86-32-debug | 11 +++++++++++ BUILD/compile-solaris-x86-32-debug-forte | 27 +++++++++++++++++++++++++++ BUILD/compile-solaris-x86-forte-32 | 19 +++++++++++++++++++ 8 files changed, 97 insertions(+), 29 deletions(-) create mode 100644 BUILD/compile-solaris-amd64-debug-forte delete mode 100755 BUILD/compile-solaris-amd64-forte-debug create mode 100644 BUILD/compile-solaris-x86-32 create mode 100644 BUILD/compile-solaris-x86-32-debug create mode 100644 BUILD/compile-solaris-x86-32-debug-forte create mode 100644 BUILD/compile-solaris-x86-forte-32 diff --git a/BUILD/compile-solaris-amd64 b/BUILD/compile-solaris-amd64 index 1373fc398fe..92eff101d4c 100755 --- a/BUILD/compile-solaris-amd64 +++ b/BUILD/compile-solaris-amd64 @@ -26,7 +26,7 @@ path=`dirname $0` extra_flags="$amd64_cflags -D__sun -m64 -mtune=athlon64" extra_configs="$amd64_configs $max_configs --with-libevent" -LDFLAGS="-lmtmalloc -static-libgcc" +LDFLAGS="-lmtmalloc -R/usr/sfw/lib/64" export LDFLAGS . "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-amd64-debug b/BUILD/compile-solaris-amd64-debug index 3bc095ae385..38e910ae7c9 100755 --- a/BUILD/compile-solaris-amd64-debug +++ b/BUILD/compile-solaris-amd64-debug @@ -5,7 +5,7 @@ path=`dirname $0` extra_flags="$amd64_cflags -D__sun -m64 -mtune=athlon64 $debug_cflags" extra_configs="$amd64_configs $debug_configs $max_configs --with-libevent" -LDFLAGS="-lmtmalloc -static-libgcc" +LDFLAGS="-lmtmalloc -R/usr/sfw/lib/64" export LDFLAGS . "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-amd64-debug-forte b/BUILD/compile-solaris-amd64-debug-forte new file mode 100644 index 00000000000..7ccf0f3a9a3 --- /dev/null +++ b/BUILD/compile-solaris-amd64-debug-forte @@ -0,0 +1,27 @@ +#!/bin/sh + +path=`dirname $0` +. "$path/SETUP.sh" + +# Take only #define options - the others are gcc specific. +# (real fix is for SETUP.sh not to put gcc specific options in $debug_cflags) +DEFS="" +for F in $debug_cflags ; do + expr "$F" : "^-D" && DEFS="$DEFS $F" +done +debug_cflags="-O0 -g $DEFS" + +extra_flags="-m64 -mt -D_FORTEC_ -xlibmopt -fns=no $debug_cflags" +extra_configs="$max_configs --with-libevent $debug_configs" + +warnings="" +c_warnings="" +cxx_warnings="" +base_cxxflags="-noex" + +CC=cc +CFLAGS="-xstrconst" +CXX=CC +LDFLAGS="-lmtmalloc" + +. "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-amd64-forte-debug b/BUILD/compile-solaris-amd64-forte-debug deleted file mode 100755 index 7ccf0f3a9a3..00000000000 --- a/BUILD/compile-solaris-amd64-forte-debug +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh - -path=`dirname $0` -. "$path/SETUP.sh" - -# Take only #define options - the others are gcc specific. -# (real fix is for SETUP.sh not to put gcc specific options in $debug_cflags) -DEFS="" -for F in $debug_cflags ; do - expr "$F" : "^-D" && DEFS="$DEFS $F" -done -debug_cflags="-O0 -g $DEFS" - -extra_flags="-m64 -mt -D_FORTEC_ -xlibmopt -fns=no $debug_cflags" -extra_configs="$max_configs --with-libevent $debug_configs" - -warnings="" -c_warnings="" -cxx_warnings="" -base_cxxflags="-noex" - -CC=cc -CFLAGS="-xstrconst" -CXX=CC -LDFLAGS="-lmtmalloc" - -. "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-x86-32 b/BUILD/compile-solaris-x86-32 new file mode 100644 index 00000000000..29965524479 --- /dev/null +++ b/BUILD/compile-solaris-x86-32 @@ -0,0 +1,11 @@ +#!/bin/sh + +path=`dirname $0` +. "$path/SETUP.sh" +extra_flags="-D__sun -m32" +extra_configs="$max_configs --with-libevent" + +LDFLAGS="-lmtmalloc -R/usr/sfw/lib" +export LDFLAGS + +. "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-x86-32-debug b/BUILD/compile-solaris-x86-32-debug new file mode 100644 index 00000000000..9ce91495c1c --- /dev/null +++ b/BUILD/compile-solaris-x86-32-debug @@ -0,0 +1,11 @@ +#!/bin/sh + +path=`dirname $0` +. "$path/SETUP.sh" +extra_flags="-D__sun -m32 $debug_cflags" +extra_configs="$max_configs --with-libevent $debug_configs" + +LDFLAGS="-lmtmalloc -R/usr/sfw/lib" +export LDFLAGS + +. "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-x86-32-debug-forte b/BUILD/compile-solaris-x86-32-debug-forte new file mode 100644 index 00000000000..777360865a2 --- /dev/null +++ b/BUILD/compile-solaris-x86-32-debug-forte @@ -0,0 +1,27 @@ +#!/bin/sh + +path=`dirname $0` +. "$path/SETUP.sh" + +# Take only #define options - the others are gcc specific. +# (real fix is for SETUP.sh not to put gcc specific options in $debug_cflags) +DEFS="" +for F in $debug_cflags ; do + expr "$F" : "^-D" && DEFS="$DEFS $F" +done +debug_cflags="-O0 -g $DEFS" + +extra_flags="-m32 -mt -D_FORTEC_ -xbuiltin=%all -xlibmil -xlibmopt -fns=no -xprefetch=auto -xprefetch_level=3 $debug_cflags" +extra_configs="$max_configs --with-libevent $debug_configs" + +warnings="" +c_warnings="" +cxx_warnings="" +base_cxxflags="-noex" + +CC=cc +CFLAGS="-xstrconst" +CXX=CC +LDFLAGS="-lmtmalloc" + +. "$path/FINISH.sh" diff --git a/BUILD/compile-solaris-x86-forte-32 b/BUILD/compile-solaris-x86-forte-32 new file mode 100644 index 00000000000..5aac376a44c --- /dev/null +++ b/BUILD/compile-solaris-x86-forte-32 @@ -0,0 +1,19 @@ +#!/bin/sh + +path=`dirname $0` +. "$path/SETUP.sh" + +extra_flags="-m32 -mt -D_FORTEC_ -xbuiltin=%all -xlibmil -xlibmopt -fns=no -xprefetch=auto -xprefetch_level=3" +extra_configs="$max_configs --with-libevent" + +warnings="" +c_warnings="" +cxx_warnings="" +base_cxxflags="-noex" + +CC=cc +CFLAGS="-xstrconst" +CXX=CC +LDFLAGS="-lmtmalloc" + +. "$path/FINISH.sh" -- cgit v1.2.1