blob: 1dd81c7cc7447bb7416dfd99e54814d31ba39afb (
plain)
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
39
40
41
42
43
44
|
EMCMODULESRCS := emc/usr_intf/axis/extensions/emcmodule.cc
MINIGLMODULESRCS := emc/usr_intf/axis/extensions/minigl.c
TOGLMODULESRCS := emc/usr_intf/axis/extensions/_toglmodule.c
PYSRCS += $(EMCMODULESRCS) $(MINIGLMODULESRCS) $(TOGLMODULESRCS)
EMCMODULE := ../lib/python/linuxcnc.so
MINIGLMODULE := ../lib/python/minigl.so
TOGLMODULE := ../lib/python/_togl.so
$(call TOOBJSDEPS, $(TOGLMODULESRCS)) : EXTRAFLAGS = $(ULFLAGS) $(TCL_CFLAGS)
$(call TOOBJSDEPS, $(EMCMODULESRCS)) : Makefile.inc
$(EMCMODULE): $(call TOOBJS, $(EMCMODULESRCS)) ../lib/liblinuxcnc.a ../lib/libnml.so.0 ../lib/liblinuxcncini.so
$(ECHO) Linking python module $(notdir $@)
$(Q)$(CXX) $(LDFLAGS) -shared -o $@ $^ -L/usr/X11R6/lib -lm -lGL
$(MINIGLMODULE): $(call TOOBJS, $(MINIGLMODULESRCS))
$(ECHO) Linking python module $(notdir $@)
$(Q)$(CC) $(LDFLAGS) -shared -o $@ $^ -L/usr/X11R6/lib -lGLU -lGL
$(TOGLMODULE): $(call TOOBJS, $(TOGLMODULESRCS))
$(ECHO) Linking python module $(notdir $@)
$(Q)$(CC) $(LDFLAGS) -shared -o $@ $(TCL_CFLAGS) $^ -L/usr/X11R6/lib -lX11 -lGL -lGLU -lXmu $(TCL_LIBS)
PYTARGETS += $(EMCMODULE) $(MINIGLMODULE) $(TOGLMODULE)
PYSCRIPTS := axis.py axis-remote.py linuxcnctop.py hal_manualtoolchange.py \
mdi.py image-to-gcode.py lintini.py debuglevel.py teach-in.py tracking-test.py
PYBIN := $(patsubst %.py,../bin/%,$(PYSCRIPTS))
PYTARGETS += $(PYBIN)
$(PYBIN): ../bin/%: emc/usr_intf/axis/scripts/%.py
@$(ECHO) Syntax checking python script $(notdir $@)
$(Q)$(PYTHON) -c 'import sys; compile(open(sys.argv[1]).read(), sys.argv[1], "exec")' $<
$(ECHO) Copying python script $(notdir $@)
$(Q)(echo '#!$(PYTHON)'; sed '1 { /^#!/d; }' $<) > $@.tmp && chmod +x $@.tmp && mv -f $@.tmp $@
PYI18NSRCS += $(addprefix emc/usr_intf/axis/scripts/, $(PYSCRIPTS)) \
../lib/python/propertywindow.py \
../share/axis/tcl/axis.tcl
|