-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
travis: fix test environment installation
The CLIPS source zip seems corrupted. Fetch CLIPS package from Debian Unstable. Signed-off-by: Matteo Cafasso <noxdafox@gmail.com>
- Loading branch information
Showing
2 changed files
with
4 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,14 @@ | ||
#!/bin/bash | ||
|
||
WORK_DIR=$(pwd) | ||
CLIPS_DIR=$WORK_DIR/clips_core_source_630 | ||
DOWNLOAD_URL="https://downloads.sourceforge.net/project/clipsrules/CLIPS/6.30/clips_core_source_630.zip" | ||
DEBIAN_UNSTABLE="deb http://ftp.se.debian.org/debian/ sid main" | ||
|
||
wget -O clips.zip $DOWNLOAD_URL | ||
echo DEBIAN_UNSTABLE | sudo tee /etc/apt/sources.list.d/debian_unstable.list | ||
|
||
unzip clips.zip | ||
|
||
cd $CLIPS_DIR | ||
|
||
cp makefiles/makefile.lib core/Makefile | ||
|
||
cd $CLIPS_DIR/core/ | ||
|
||
sed -i 's/gcc -c/gcc -fPIC -c/g' Makefile | ||
|
||
make | ||
|
||
ld -G *.o -o libclips.so | ||
|
||
cd $WORK_DIR | ||
sudo apt update | ||
sudo apt install -t sid libclips libclips-dev | ||
|
||
sudo pip install --upgrade pip | ||
sudo pip install --upgrade setuptools | ||
sudo pip install --upgrade pytest | ||
|
||
python setup.py build_ext --include-dirs $CLIPS_DIR/core/ --library-dirs $CLIPS_DIR/core/ | ||
python setup.py install | ||
|
||
CFLAGS="-I$CLIPS_DIR/core/" LDFLAGS="-L$CLIPS_DIR/core/" python clips/clips_build.py | ||
|
||
mv _clips* clips/ |