File: dylib

package info (click to toggle)
poco 1.14.2-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 56,460 kB
  • sloc: cpp: 340,542; ansic: 245,601; makefile: 1,742; yacc: 1,005; sh: 698; sql: 312; lex: 282; xml: 128; perl: 29; python: 24
file content (82 lines) | stat: -rw-r--r-- 2,860 bytes parent folder | download
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#
# dylib
#
# Rule definitions for building dynamically loadable shared libraries
#

#
# Target names
#
SHL_EXT = $(SHAREDLIBLINKEXT)

# Some systems (e.g. Mac OS X) make a difference between
# shared libraries (as used by the linker/loader) and
# dynamic libraries, as used for dynamically loadable modules.
# If no specific instructions for making dynamic libraries
# are given, use the instructions for making shared libraries.

ifndef DYLIB
DYLIB      = $(SHLIB)
DYLIBFLAGS = $(SHLIBFLAGS)
endif

target := $(strip $(target))
target_version := $(strip $(target_version))
target_libs := $(strip $(target_libs))

DYLIB_DEBUG        = $(BINPATH)/$(target)d$(OSARCH_POSTFIX)$(SHL_EXT)
DYLIB_RELEASE      = $(BINPATH)/$(target)$(OSARCH_POSTFIX)$(SHL_EXT)
DYLIB_S_DEBUG      = $(BINPATH)/static/$(target)d$(OSARCH_POSTFIX)$(SHL_EXT)
DYLIB_S_RELEASE    = $(BINPATH)/static/$(target)$(OSARCH_POSTFIX)$(SHL_EXT)

TARGET_LIBS_DEBUG       = $(foreach l,$(target_libs),-l$(l)d$(OSARCH_POSTFIX))
TARGET_LIBS_RELEASE     = $(foreach l,$(target_libs),-l$(l)$(OSARCH_POSTFIX))
TARGET_LIBS_EXT_DEBUG   = $(foreach l,$(target_extlibs),-l$(l)d$(OSARCH_POSTFIX))
TARGET_LIBS_EXT_RELEASE = $(foreach l,$(target_extlibs),-l$(l)$(OSARCH_POSTFIX))

#
# Include the compile rules
#
include $(POCO_BASE)/build/rules/compile

#
# Rules for creating a dynamically loadable shared library
#
clean:
	$(RM) $(POCO_BUILD_STDERR_FILE)
	$(RM) $(OBJPATH)
	$(RM) $(DYLIB_DEBUG) $(DYLIB_RELEASE) $(DYLIB_S_DEBUG) $(DYLIB_S_RELEASE)

distclean: clean
	$(RM) obj
	$(RM) .dep

static_debug:   static_bindirs $(DYLIB_S_DEBUG)
static_release: static_bindirs $(DYLIB_S_RELEASE)
shared_debug:   bindirs $(DYLIB_DEBUG)
shared_release: bindirs $(DYLIB_RELEASE)

$(DYLIB_DEBUG): $(prebuild) $(foreach o,$(objects),$(OBJPATH_DEBUG_SHARED)/$(o).o)
	@echo "** Building dynamic library (debug, shared)" $@
	$(DYLIB) $(DYLIBFLAGS) $^ $(LIBRARY) $(TARGET_LIBS_DEBUG) $(TARGET_LIBS_EXT_DEBUG) $(SYSLIBS)
	$(postbuild)

$(DYLIB_RELEASE): $(prebuild) $(foreach o,$(objects),$(OBJPATH_RELEASE_SHARED)/$(o).o)
	@echo "** Building dynamic library (release, shared)" $@
	$(DYLIB) $(DYLIBFLAGS) $^ $(LIBRARY) $(TARGET_LIBS_RELEASE) $(TARGET_LIBS_EXT_RELEASE) $(SYSLIBS)
	$(postbuild)

$(DYLIB_S_DEBUG): $(prebuild) $(foreach o,$(objects),$(OBJPATH_DEBUG_SHARED)/$(o).o)
	@echo "** Building dynamic library (debug, static)" $@
	$(DYLIB) $(DYLIBFLAGS) $^ $(LIBRARY) $(TARGET_LIBS_DEBUG) $(TARGET_LIBS_EXT_DEBUG) $(SYSLIBS)
	$(postbuild)

$(DYLIB_S_RELEASE): $(prebuild) $(foreach o,$(objects),$(OBJPATH_RELEASE_SHARED)/$(o).o)
	@echo "** Building dynamic library (release, static)" $@
	$(DYLIB) $(DYLIBFLAGS) $^ $(LIBRARY) $(TARGET_LIBS_RELEASE) $(TARGET_LIBS_EXT_RELEASE) $(SYSLIBS)
	$(postbuild)

#
# Include the automatically generated dependency files
#
sinclude $(addprefix $(DEPPATH)/,$(addsuffix .d,$(objects)))