monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Monotone-devel] How to compile monotone 0.13 on Solaris 9/SPARC


From: Sven Kirmess
Subject: [Monotone-devel] How to compile monotone 0.13 on Solaris 9/SPARC
Date: Sat, 19 Jun 2004 16:15:59 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6) Gecko/20040113

1) First, we need the GNU binutils. The strange build process of boost
   does not support the Solaris linker. Usually, it's a bad idea to use
   the GNU binutils on Solaris be we do not have a choice...

   I tried to compile the newest binutils from source (2.15) but
   the compilation of monotone broke. I therefore comiled 2.11.2.

   I used the following configure options to build binutils:

        --prefix=/opt/binutils                                          \
        --sysconfdir=/etc/opt/binutils                                  \
        --localstatedir=/var/opt/binutils                               \
        --program-prefix=g                                              \
        --with-PACKAGE=no


2) Now, we need a GCC compiler, compiled to use gld and gas from the
   GNU binutils. The GCC 3.4.0 did not work for me (problem while
   compiling monotone). I therefore compiled 3.3.3. I used the
   following configure options to configure GCC 3.3.3:

        --prefix=/opt/gcc                                               \
        --with-gnu-as                                                   \
        --with-as=/opt/binutils/bin/gas                                 \
        --with-gnu-ld                                                   \
        --with-ld=/opt/binutils/bin/gld                                 \
        --disable-shared                                                \
        --disable-nls                                                   \
        --enable-languages=c,c++

   Note: You should have another GCC compiler which uses Sun ld and Sun as
   on your system to compile all other software. Only the broken boost
   build process requires this special GCC.


3) After that, we have to build the boost library. I used version 1.31.0.
   This is how I built and installed it. It is a slight modification of the
   information found on the monotone homepage:

   NOTE: It is very important, that the GCC compiler created in step 2)
   is the first C and C++ compiler in your PATH!

   $ bzcat boost_1_31_0.tar.bz2 | (cd /tmp; gtar xvf -)
   $ cd /tmp/boost_1_31_0/tools/build/jam_src;                          \
     bash ./build.sh

   $ cd /tmp/boost_1_31_0;                                              \
     /tmp/boost_1_31_0/tools/build/jam_src/bin.solaris/bjam             \
       --prefix=/opt/boost                                              \
       "-sBUILD=release <threading>single <optimization>speed 
<runtime-link>static"

   $ cd /tmp/boost_1_31_0;                                              \
     /tmp/boost_1_31_0/tools/build/jam_src/bin.solaris/bjam
       --prefix=/opt/boost                                              \
       "-sBUILD=release <threading>single <optimization>speed 
<runtime-link>static" \
      install

   $ cd /opt/boost/include;                                             \
     mv boost-*/boost ./;                                               \
     rmdir boost-*

   $ cd /opt/boost;                                                     \
     mkdir lib-so;                                                      \
     cd lib;                                                            \
     mv *.so ../lib-so/

   $ cd /opt/boost/lib;                                                 \
     for i in *-gcc-s.a; do                                             \
       ln $i `echo $i | sed -e 's,-gcc-s\.a$,.a,'`;                     \
     done


4) Then, we can finally build monotone. I used the following configure
   options:

        --prefix=/opt/monotone                                          \
        --sysconfdir=/etc/opt/monotone                                  \
        --localstatedir=/var/opt/monotone                               \
        --with-PACKAGE=no                                               \
        --enable-static-boost                                           \
        --disable-nls                                                   \
        CPPFLAGS="-I /opt/boost/include -I /opt/popt-1.7/include"       \
        LDFLAGS="-L /opt/boost/lib -L /opt/popt-1.7/lib"

   Before compiling monotone, I had to apply the following patch to
   configure:

--- configure.orig      Sat Jun  5 22:48:55 2004
+++ configure   Sat Jun  5 22:48:31 2004
@@ -8217,7 +8217,7 @@
 then
    echo "$as_me:$LINENO: checking location of static boost libraries" >&5
 echo $ECHO_N "checking location of static boost libraries... $ECHO_C" >&6
+   for i in /lib /usr/lib /opt/lib /usr/local/lib /opt/boost/lib
-   for i in /lib /usr/lib /opt/lib /usr/local/lib
    do
        if test -e $i/libboost_regex.a
        then


--
Sven




reply via email to

[Prev in Thread] Current Thread [Next in Thread]