File: get-abc

package info (click to toggle)
cvc4 1.8-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 69,876 kB
  • sloc: cpp: 274,686; sh: 5,833; python: 1,893; java: 929; lisp: 763; ansic: 275; perl: 214; makefile: 22; awk: 2
file content (38 lines) | stat: -rwxr-xr-x 1,403 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/usr/bin/env bash
#
source "$(dirname "$0")/get-script-header.sh"

ABC_DIR="$DEPS_DIR/abc"
commit=53f39c11b58d

check_dep_dir "$ABC_DIR"
setup_dep "https://bitbucket.org/alanmi/abc/get/$commit.tar.gz" "$ABC_DIR"
cd "$ABC_DIR"

# Strip out libSupport.c, it is in charge of loading extensions and we
# don't want different behavior based on ABC_LIB_PATH, or based on what
# .so is in the current directory!
cp src/base/main/module.make src/base/main/module.make.orig
grep -v 'libSupport\.c' src/base/main/module.make.orig > src/base/main/module.make
cp src/base/main/mainInit.c src/base/main/mainInit.c.orig
sed 's,\( *\)\(.*Libs_Init(\),\1//\2,;s,\( *\)\(.*Libs_End(\),\1//\2,' src/base/main/mainInit.c.orig > src/base/main/mainInit.c

# Build optimized, without readline, without pthreads.
# These aren't necessary for our usage and we don't want the dependencies.
make -j$(nproc) libabc.a OPTFLAGS=-O ABC_USE_NO_READLINE=1 ABC_USE_NO_PTHREADS=1
mv libabc.a libabc-static.a
install_lib libabc-static.a
make clean

make -j$(nproc) libabc.a OPTFLAGS='-O -fPIC' ABC_USE_NO_READLINE=1 ABC_USE_NO_PTHREADS=1
install_lib libabc.a
install_bin arch_flags

# Copy headers and preserve subdirectories
cd src
mkdir -p "$INSTALL_INCLUDE_DIR/abc"
cp --parents $(find . -name '*.h') "$INSTALL_INCLUDE_DIR/abc"

echo
echo ===================== Now configure CVC4 with =====================
echo ./configure.sh --abc