-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
37 lines (27 loc) · 924 Bytes
/
Makefile
File metadata and controls
37 lines (27 loc) · 924 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
37
#ifndef pythonMaj
pythonMaj = 3
#endif
#ifndef pythonMin
pythonMin = .6m
#endif
libtarget = lib/libjpython.so
bin_src = callpython_test.jabba
binobject = jabba]MOBJECT/$(patsubst %.jabba,%.o,$(bin_src))
bintarget = bin/$(patsubst %.jabba,%,$(bin_src))
jabba_src = python_class.jabba
jabba_object=$(patsubst %.jabba,%.o,$(jabba_src))
libobject = classes/$(jabba_object)
headers = include/jbcpython_common.h
linklib = python$(pythonMaj)$(pythonMin)
targets: $(bintarget) $(libtarget)
all: targets
$(libobject): classes/$(jabba_src) $(headers)
BASIC -I.. -I/usr/include/python$(pythonMaj)$(pythonMin) classes $(jabba_src)
$(libtarget): $(libobject)
cd classes && jcompile -o../$(libtarget) $(jabba_object) -l$(linklib)
$(binobject): jabba/$(bin_src) $(headers)
BASIC jabba $(bin_src)
$(bintarget): $(binobject)
CATALOG -o./bin jabba $(bin_src)
clean:
-rm -f $(bintarget)* $(binobject) $(libtarget)* $(libobject)