-
Notifications
You must be signed in to change notification settings - Fork 31
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
11 additions
and
25 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,23 @@ | ||
#!/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 | ||
sudo apt-get --allow-unauthenticated update | ||
sudo apt full-upgrade | ||
sudo apt install locate | ||
sudo apt install -y --allow-unauthenticated -t sid libclips libclips-dev | ||
|
||
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 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 | ||
sudo updatedb | ||
locate clips.h | ||
|
||
CFLAGS="-I$CLIPS_DIR/core/" LDFLAGS="-L$CLIPS_DIR/core/" python clips/clips_build.py | ||
ls -ahl /usr/include | ||
ls -ahl /usr/include/clips | ||
|
||
mv _clips* clips/ | ||
pip install . |