3 # Copyright (C) 2015 - Jonathan Rajotte-Julien <jonathan.rajotte-julien@efficios.com>
5 # This program is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation, either version 3 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program. If not, see <http://www.gnu.org/licenses/>.
18 # Create build directory
19 rm -rf $WORKSPACE/build
20 mkdir
-p $WORKSPACE/build
22 PREFIX
="$WORKSPACE/build"
40 BISON
="/opt/csw/bin/bison"
42 export PATH
="$PATH:/usr/perl5/bin"
56 CONF_OPTS
="--enable-static --disable-shared"
59 echo "Build with python bindings"
60 # We only support bindings built with Python 3
61 export PYTHON
="python3"
62 export PYTHON_CONFIG
="/usr/bin/python3-config"
63 CONF_OPTS
="--enable-python-bindings"
72 # oot : out-of-tree build
73 # dist: build via make dist
74 # * : normal tree build
76 # Make sure to move to the build_path and configure
80 TEST_PLAN_PATH
=$WORKSPACE
84 echo "Out of tree build"
85 BUILD_PATH
=$WORKSPACE/oot
88 MAKE
=$MAKE BISON
="$BISON" YACC
="$YACC" $WORKSPACE/configure
--prefix=$PREFIX $CONF_OPTS
91 echo "Distribution out of tree build"
92 BUILD_PATH
=`mktemp -d`
94 # Initial configure and generate tarball
95 MAKE
=$MAKE BISON
="$BISON" YACC
="$YACC" .
/configure
99 cp *.
tar.
* $BUILD_PATH/
102 # Ignore level 1 of tar
103 $TAR xvf
*.
tar.
* --strip 1
105 MAKE
=$MAKE BISON
="$BISON" YACC
="$YACC" $BUILD_PATH/configure
--prefix=$PREFIX $CONF_OPTS
107 # Set test plan to dist tar
108 TEST_PLAN_PATH
=$BUILD_PATH
111 echo "Standard tree build"
112 MAKE
=$MAKE BISON
="$BISON" YACC
="$YACC" $WORKSPACE/configure
--prefix=$PREFIX $CONF_OPTS
121 # Cleanup rpath and libtool .la files
122 #find $WORKSPACE/build/bin -executable -type f -exec chrpath --delete {} \;
123 find $WORKSPACE/build
/lib
-name "*.so" -exec chrpath
--delete {} \
;
124 find $WORKSPACE/build
/lib
-name "*.la" -exec rm -f {} \
;
126 if [ $build = "dist" ]; then
This page took 0.034111 seconds and 5 git commands to generate.