]> err.no Git - sope/blob - sope-appserver/SoOFS/GNUmakefile.preamble
work on OSX frameworks
[sope] / sope-appserver / SoOFS / GNUmakefile.preamble
1 # compilation settings
2
3 ADDITIONAL_CPPFLAGS += -Wall -DCOMPILE_FOR_GSTEP_MAKE=1
4 ADDITIONAL_OBJCFLAGS += -Wall -Wno-import -Wno-protocol
5
6 SOPE_ROOT=../..
7 CORE_ROOT=$(SOPE_ROOT)/sope-core
8
9 ADDITIONAL_INCLUDE_DIRS += \
10         -I.                     \
11         -I..                    \
12         -I../NGObjWeb           \
13         -I$(CORE_ROOT)          \
14         -I$(CORE_ROOT)/NGStreams/       \
15         -I$(CORE_ROOT)/NGExtensions     \
16         -I$(SOPE_ROOT)/sope-xml
17
18
19 ifneq ($(frameworks),yes)
20
21 libSoOFS_LIBRARIES_DEPEND_UPON += \
22         -lNGObjWeb \
23         -lNGMime -lNGStreams -lNGExtensions -lEOControl \
24         -lXmlRpc -lDOM -lSaxObjC
25
26 $(SOPED_NAME)_TOOL_LIBS += \
27         -lSoOFS -lNGObjWeb \
28         -lNGMime -lNGStreams -lNGExtensions -lEOControl \
29         -lXmlRpc -lDOM -lSaxObjC
30
31 SoOFS_WOBUNDLE_LIBS += \
32         -lSoOFS         \
33         -lNGObjWeb      \
34         -lNGMime        \
35         -lNGStreams -lNGExtensions -lEOControl \
36         -lXmlRpc -lDOM -lSaxObjC
37 SoOFS_BUNDLE_LIBS   += $(SoOFS_WOBUNDLE_LIBS)
38
39 else
40
41 SoOFS_LIBRARIES_DEPEND_UPON += \
42         -framework NGObjWeb \
43         -framework NGMime       \
44         -framework NGStreams -framework NGExtensions -framework EOControl \
45         -framework XmlRpc -framework DOM -framework SaxObjC
46
47 $(SOPED_NAME)_TOOL_LIBS += \
48         -framework SoOFS -framework NGObjWeb \
49         -framework NGMime \
50         -framework NGStreams -framework NGExtensions -framework EOControl \
51         -framework XmlRpc -framework DOM -framework SaxObjC
52
53 endif
54
55
56 # library/framework search pathes
57
58 DEP_DIRS = \
59         . ../NGObjWeb \
60         $(SOPE_ROOT)/sope-mime                  \
61         $(SOPE_ROOT)/sope-core/NGStreams        \
62         $(SOPE_ROOT)/sope-core/NGExtensions     \
63         $(SOPE_ROOT)/sope-core/EOControl        \
64         $(SOPE_ROOT)/sope-xml/DOM               \
65         $(SOPE_ROOT)/sope-xml/XmlRpc            \
66         $(SOPE_ROOT)/sope-xml/SaxObjC
67
68 ifneq ($(frameworks),yes)
69 ADDITIONAL_LIB_DIRS += \
70         $(foreach dir,$(DEP_DIRS),\
71           -L$(GNUSTEP_BUILD_DIR)/$(dir)/$(GNUSTEP_OBJ_DIR_NAME))
72 else
73 ADDITIONAL_LIB_DIRS += \
74         $(foreach dir,$(DEP_DIRS),-F$(GNUSTEP_BUILD_DIR)/$(dir))
75 endif
76
77 SYSTEM_LIB_DIR += -L/usr/local/lib -L/usr/lib
78
79
80
81 # platform specific settings
82
83 ifneq ($(findstring openbsd3, $(GNUSTEP_TARGET_OS)), openbsd3)
84 # OpenBSD does not require libcrypt
85 ifneq ($(findstring darwin, $(GNUSTEP_TARGET_OS)), darwin)
86 # and neither does MacOSX? ...
87 sope_TOOL_LIBS += -lcrypt
88 endif
89 endif
90
91 ifeq ($(findstring openbsd3, $(GNUSTEP_TARGET_OS)), openbsd3)
92 $(SOPED_NAME)_TOOL_LIBS += -liconv
93 endif