2 # Copyright (c) 2013 Vojtech Horky
5 # Redistribution and use in source and binary forms, with or without
6 # modification, are permitted provided that the following conditions
9 # - Redistributions of source code must retain the above copyright
10 # notice, this list of conditions and the following disclaimer.
11 # - Redistributions in binary form must reproduce the above copyright
12 # notice, this list of conditions and the following disclaimer in the
13 # documentation and/or other materials provided with the distribution.
14 # - The name of the author may not be used to endorse or promote products
15 # derived from this software without specific prior written permission.
17 # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
18 # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
19 # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20 # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22 # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26 # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32 shipsources="http://isl.gforge.inria.fr/${shipname_}-${shipversion}.tar.bz2"
37 run tar xjf "${shipname_}-${shipversion}.tar.bz2"
38 cd ${shipname_}-${shipversion}
40 extra_cflags="-I$HSCT_INCLUDE_DIR -L$HSCT_LIB_DIR"
44 --host="$HSCT_GNU_TARGET" \
46 CFLAGS="$HSCT_CFLAGS $HSCT_LDFLAGS_FOR_CC $extra_cflags" \
50 OBJDUMP="$HSCT_OBJDUMP" \
54 run make -j$shipfunnels STATIC_ONLY=y
58 cd "${shipname_}-${shipversion}"
59 run make install "DESTDIR=$PWD/PKG"
61 # Copy the headers and static library
62 run mkdir -p "$HSCT_INCLUDE_DIR/${shipname_}"
63 run cp PKG/usr/local/include/isl/*.h "$HSCT_INCLUDE_DIR/isl"
64 run cp PKG/usr/local/lib/libisl.a "$HSCT_LIB_DIR/"
66 run mkdir -p "$HSCT_MY_DIR/inc/c/isl"
67 run cp PKG/usr/local/include/isl/*.h "$HSCT_MY_DIR/inc/c/isl"
69 run mkdir -p "$HSCT_MY_DIR/lib"
70 run cp PKG/usr/local/lib/libisl.a "$HSCT_MY_DIR/lib"
73 msg "Preparing tests..."
74 run mkdir -p "$HSCT_MY_DIR/tests/${shipname}/"
75 run cp isl_pip "$HSCT_MY_DIR/tests/${shipname}/"
77 run cp *.pip "$HSCT_MY_DIR/tests/${shipname}/"
78 echo "echo Running ${shipname} tests..." >"$HSCT_MY_DIR/tests/run_${shipname}.bdsh"
79 for testname in *.pip; do
80 # This is taken from pip_test.sh
81 cat >>"$HSCT_MY_DIR/tests/run_${shipname}.bdsh" <<EOF_PIP_TEST
82 echo --- $testname ---
83 from /tests/${shipname}/$testname | /tests/${shipname}/isl_pip --format=set --context=gbr -T
84 from /tests/${shipname}/$testname | /tests/${shipname}/isl_pip --format=set --context=lexmin -T
85 from /tests/${shipname}/$testname | /tests/${shipname}/isl_pip --format=affine --context=gbr -T
86 from /tests/${shipname}/$testname | /tests/${shipname}/isl_pip --format=affine --context=lexmin -T