File: gnumake-gcc-flext.inc

package info (click to toggle)
pd-flext 0.6.4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,960 kB
  • sloc: cpp: 12,978; makefile: 223; sh: 149
file content (57 lines) | stat: -rw-r--r-- 1,362 bytes parent folder | download | duplicates (6)
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
45
46
47
48
49
50
51
52
53
54
55
56
57
# build class specific settings

#ifdef SHARED
#LDFLAGS += -install_name $(FLEXTLIB)/$(TARGETNAME)
#LDFLAGS += -current_version $(FLEXTMAJOR).$(FLEXTMINOR).$(FLEXTMICRO)
#LDFLAGS += -compatibility_version $(FLEXTMAJOR).$(FLEXTMINOR)
#LDFLAGS += -preload -seg1addr 0xd0000000
#endif

# common compilation stuff
include $(BUILDPATH)$(PLATFORM)/gnumake-gcc-targets.inc

##### linking ###################

$(TARGET) :: $(OBJPATH) $(TARGETPATH)

$(TARGET) :: $(PRECOMDST) $(COBJS) $(CPPOBJS)
ifdef SHARED
	$(CXX) $(LDFLAGS) $(LIBPATH) -o $@ $(COBJS) $(CPPOBJS) $(LIBS)
ifdef DEBUG
else
ifdef PROFILE
else
	strip -x $@
endif
endif
	chmod 755 $@
else
	$(AR) rc $@ $(COBJS) $(CPPOBJS)
endif

ifdef TARGETPOST
$(TARGET) :: $(TARGETPOST)
endif

###################################

$(FLEXTINC):
	-mkdir -p $@

$(FLEXTLIB):
	-mkdir -p $@

_install_: $(FLEXTINC) $(FLEXTLIB)
# --- install as dynamic library ---
	install $(TARGET) $(FLEXTLIB)
ifdef VERNAME
	ln -sf $(VERNAME) $(FLEXTLIB)/$(TARGETNAME)
endif
	install $(patsubst %,$(SRCDIR)/%,$(HDRS) $(SRCS)) $(FLEXTINC)
# transfer build system
#	cp -rf buildsys $(FLEXTSYS)
#	install build.sh $(FLEXTSYS)
#	chmod -R a+rx $(FLEXTSYS)
# make convenience script
#	echo bash $(FLEXTSYS)/build.sh $$\* > $(FLEXTBIN)/flext-build.sh
#	chmod a+rx $(FLEXTBIN)/flext-build.sh