]>
Commit | Line | Data |
---|---|---|
435227b9 A |
1 | include $(CoreOSMakefiles)/ProjectBuilder/Makefile.Postamble.Common |
2 | ||
3 | ifeq "$(BUILD_TYPE)" "normal" | |
4 | LIBS += -lcc_noc++ | |
5 | else | |
6 | LIBS = | |
7 | endif | |
8 | ||
9 | LIBS := $(foreach LIB, \ | |
10 | $(filter $(BSD_LIBS), $(subst -l,,$(LIBS))), \ | |
11 | $(NEXT_ROOT)/usr/local/lib/system/lib$(LIB).a) \ | |
12 | $(filter-out $(addprefix -l, $(BSD_LIBS)), $(LIBS)) | |
13 | ||
14 | # pb_makefiles erroneously omits $(BUILD_TYPE_SUFFIX) from the install name | |
15 | DYLIB_INSTALL_NAME = $(LIBRARY_PREFIX)$(NAME).$(VERSION_NAME)$(BUILD_TYPE_SUFFIX)$(LIBRARY_EXT) | |
16 | ||
17 | # The nonversioned suffix link is required by cc -pg, which is a bug in the compiler. | |
18 | # We can remove those when this is fixed. | |
19 | ||
20 | override DEBUG_SUFFIX = _debug | |
21 | PRODUCTS += $(foreach TYPE, DEBUG PROFILE, \ | |
22 | $(PRODUCT_DIR)/$(LIBRARY_PREFIX)$(NAME)$($(TYPE)_SUFFIX)$(LIBRARY_EXT) \ | |
23 | $(PRODUCT_DIR)/$(LIBRARY_PREFIX)$(NAME).$(VERSION_NAME)$($(TYPE)_SUFFIX)$(LIBRARY_EXT) \ | |
24 | ) | |
25 | ||
26 | SystemFramework = $(NSFRAMEWORKDIR)/System.framework | |
4a9703e6 | 27 | VersionDir = Versions/$(VERSION_NAME) |
435227b9 A |
28 | |
29 | compat-next: | |
30 | $(INSTALL_DIRECTORY) "$(DSTROOT)$(SystemFramework)" | |
31 | $(INSTALL_DIRECTORY) "$(DSTROOT)$(SystemFramework)/Versions" | |
4a9703e6 A |
32 | $(INSTALL_DIRECTORY) "$(DSTROOT)$(SystemFramework)/$(VersionDir)" |
33 | $(LN) -fs "$(VERSION_NAME)" "$(DSTROOT)$(SystemFramework)/Versions/Current" | |
34 | for suffix in "" $(DEBUG_SUFFIX) $(PROFILE_SUFFIX); do \ | |
35 | $(LN) -fs "Versions/Current/$(NAME)$${suffix}" "$(DSTROOT)$(SystemFramework)/$(NAME)$${suffix}" ; \ | |
36 | $(LN) -fs "../../../../../..$(INSTALLDIR)/$(LIBRARY_PREFIX)$(NAME).$(VERSION_NAME)$${suffix}$(LIBRARY_EXT)" \ | |
37 | "$(DSTROOT)$(SystemFramework)/$(VersionDir)/$(NAME)$${suffix}" ; \ | |
435227b9 | 38 | done |
4a9703e6 | 39 | $(LN) -fs "Versions/Current/PrivateHeaders" "$(DSTROOT)$(SystemFramework)" |
435227b9 A |
40 | |
41 | compat-bsd: | |
42 | for lib in $(BSD_LIBS) ; do \ | |
43 | $(LN) -fs libSystem.dylib "$(DSTROOT)$(INSTALLDIR)/lib$${lib}.dylib"; \ | |
44 | done | |
4a9703e6 A |
45 | |
46 | copy_plist: | |
47 | $(MKDIR) $(DSTROOT)$(SystemFramework)/$(VersionDir)/Resources | |
48 | $(LN) -fs Versions/Current/Resources $(DSTROOT)$(SystemFramework)/Resources | |
49 | $(RM) -f $(DSTROOT)$(SystemFramework)/$(VersionDir)/Resources/Info.plist | |
50 | $(CP) $(SRCROOT)/Info.plist $(DSTROOT)$(SystemFramework)/$(VersionDir)/Resources | |
51 | $(CHMOD) 444 $(DSTROOT)$(SystemFramework)/$(VersionDir)/Resources/Info.plist |