1 LIBWVBASE
=$(WVSTREAMS_LIB
)/libwvbase.so
$(LIBXPLC
)
2 LIBWVUTILS
=$(WVSTREAMS_LIB
)/libwvutils.so
$(LIBWVBASE
)
3 LIBWVSTREAMS
=$(WVSTREAMS_LIB
)/libwvstreams.so
$(LIBWVUTILS
)
4 LIBWVOGG
=$(WVSTREAMS_LIB
)/libwvoggvorbis.so
$(LIBWVSTREAMS
)
5 LIBUNICONF
=$(WVSTREAMS_LIB
)/libuniconf.so
$(LIBWVSTREAMS
)
6 LIBWVDBUS
=$(WVSTREAMS_LIB
)/libwvdbus.so
$(LIBWVSTREAMS
)
7 LIBWVQT
=$(WVSTREAMS_LIB
)/libwvqt.so
$(LIBWVSTREAMS
)
8 LIBWVTEST
=$(WVSTREAMS_LIB
)/libwvtest.a
$(LIBWVUTILS
)
11 # Initial C compilation flags
13 INCFLAGS
=$(addprefix -I
,$(WVSTREAMS_INC
) $(XPATH
))
15 CPPFLAGS
+= $(CPPOPTS
)
17 CXXFLAGS
+= $(CXXOPTS
)
18 LDFLAGS
+= $(LDOPTS
) -L
$(WVSTREAMS_LIB
)
20 # Default compiler we use for linking
23 ifeq ("$(enable_debug)", "yes")
29 ifeq ("$(enable_fatal_warnings)", "yes")
31 # FIXME: not for C, because our only C file, crypto/wvsslhack.c, has
32 # a few warnings on purpose.
36 ifneq ("$(enable_optimization)", "no")
38 #CXXFLAGS+=-felide-constructors
42 ifneq ("$(enable_warnings)", "no")
43 #WLACH:FIXME: Conditional on using MSVC
44 # CXXFLAGS+=-Wall -Woverloaded-virtual
48 ifeq ("$(enable_efence)", "yes")
57 ifeq ("$(enable_verbose)", "yes")
62 VERBOSE
:=1 $(warning DONT_LIE is deprecated
, use VERBOSE instead
)
66 # Figure out which OS we're running (for now, only picks out Linux or BSD)
68 OS
:=$(shell uname
-a | awk
'{print $$1}' | sed
-e
's/^.*BSD/BSD/g' )
71 # (Just BSD and LINUX clash with other symbols, so use ISLINUX and ISBSD)
72 # This sucks. Use autoconf for most things!
84 XX_LIBS
+= -lccmalloc
-ldl
89 CFLAGS
+= -ggdb
-DDEBUG
=1
90 CXXFLAGS
+= -ggdb
-DDEBUG
=1
95 #CFLAGS += -DNDEBUG # I don't like disabling assertions...
96 #CFLAGS += -fomit-frame-pointer # really evil
97 #CXXFLAGS += -fno-implement-inlines # causes trouble with egcs 1.0
111 $(LINK_MSG
)set
-e
; rm -f
$1 $(patsubst %.a
,%.libs
,$1); \
112 echo
$2 >$(patsubst %.a
,%.libs
,$1); \
113 $(AR
) q
$1 $(filter %.o
,$2); \
114 for d in
"" $(filter %.libs
,$2); do \
115 if
[ "$$d" != "" ]; then \
116 cd
$$(dirname
"$$d"); \
117 $(AR
) q
$(shell pwd
)/$1 $$(cat
$$(basename $$d)); \
126 $(COMPILE_MSG
)$4 $5 $2 -o
$1
127 @
# The Perl script here generates the proper dependencies, including
128 @
# null dependencies so Make doesn't complain
129 $(DEPEND_MSG
)$4 -M
-E
$< \
131 '$$a = '"'"'$1'"'"'; \
135 for (split(/(?<!\\)$$/m)) { \
136 s/^[^:]+:\s*/$$a: /; \
139 map {print "$$_:" unless m/^\\$$/} (split(/\s+/));\
146 $(LINK_MSG
)set
-e
; rm -f
$1 $(patsubst %.a
,%.libs
,$1); \
147 echo
$2 >$(patsubst %.a
,%.libs
,$1); \
148 $(AR
) q
$1 $(filter %.o
,$2); \
149 for d in
"" $(filter %.libs
,$2); do \
150 if
[ "$$d" != "" ]; then \
151 cd
$$(dirname
"$$d"); \
152 $(AR
) q
$(shell pwd
)/$1 $$(cat
$$(basename $$d)); \
159 wvlink
=$(LINK_MSG
)$(CC
) $(LDFLAGS
) $($1-LDFLAGS
) -o
$1 $(filter %.o
%.a
%.so
, $2) $($1-LIBS
) $(LIBS
) $(XX_LIBS
) $(LDLIBS
)