-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile.init
More file actions
36 lines (28 loc) · 797 Bytes
/
Makefile.init
File metadata and controls
36 lines (28 loc) · 797 Bytes
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
SHELL := /bin/bash
CC=gcc
CFLAGSPLPLOT= $(CFLAGS) -fPIC -Wall -g -O2 -Wextra ${INCDIRS}
all: plplot.so
plplot.o: plplot.c
$(CC) -c $(CFLAGSPLPLOT) plplot.c -o plplot.o
plplot.so: plplot.o
if test $(SWIARCH) == x64-win64 -o $(SWIARCH) == i386-win32 ; then \
$(CC) plplot.o -static-libgcc -static-libstdc++ -shared -lswipl -o plplot.so ;\
else \
if [[ $(SWIARCH) == *darwin* ]] ; then \
$(CC) plplot.o -shared -lswipl -o plplot.so ;\
else \
$(CC) -export-dynamic plplot.o -shared -o plplot.so ;\
fi \
fi
# gcc -shared -o plplot.so plplot.o
distclean: clean
rm Makefile
clean:
rm -f *.o plplot.so
check:
@echo "not available"
install: all
mkdir -p $(PACKSODIR)
cp plplot.so $(PACKSODIR)
installcheck:
swipl -g test -t halt prolog/plplot_test.pl