1 AM_CPPFLAGS = $(MULECPPFLAGS)
2 AM_CFLAGS = $(MULECFLAGS)
3 AM_CXXFLAGS = $(MULECXXFLAGS)
4 AM_LDFLAGS = $(MULELDFLAGS)
6 SUBDIRS = libs utils pixmaps
9 # build webserver after current
10 SUBDIRS += . webserver
34 bin_PROGRAMS += amulecmd
42 bin_PROGRAMS += amulegui
46 bin_PROGRAMS += amuled
50 noinst_LIBRARIES = libmulesocket.a
52 noinst_LIBRARIES += libmuleappcore.a libmuleappgui.a libmuleappcommon.a
55 noinst_LIBRARIES += libmuleappcore.a libmuleappcommon.a
58 noinst_LIBRARIES += libmuleappgui.a libmuleappcommon.a
64 # Socket lib (WX or Asio)
66 libmulesocket_a_SOURCES = LibSocket.cpp
67 libmulesocket_a_CPPFLAGS = $(AM_CPPFLAGS) $(WXBASE_CPPFLAGS) $(BOOST_CPPFLAGS) -I$(srcdir)/libs -I$(srcdir)/include
70 # Common to core/gui/monolithic
72 libmuleappcommon_a_SOURCES = \
80 NetworkFunctions.cpp \
87 TerminationProcess.cpp \
90 libmuleappcommon_a_CPPFLAGS = $(AM_CPPFLAGS) $(WXBASE_CPPFLAGS) -I$(srcdir)/libs -I$(srcdir)/include $(CRYPTOPP_CPPFLAGS) $(LIBUPNP_CPPFLAGS)
93 # Common to core/monolithic
95 libmuleappcore_a_SOURCES = \
100 IPFilterScanner.cpp \
103 PlatformSpecific.cpp \
104 RandomFunctions.cpp \
107 TerminationProcessAmuleweb.cpp \
108 ThreadScheduler.cpp \
110 kademlia/kademlia/Entry.cpp \
111 kademlia/kademlia/SearchManager.cpp \
112 kademlia/routing/RoutingBin.cpp \
113 kademlia/utils/UInt128.cpp
115 libmuleappcore_a_CPPFLAGS = $(AM_CPPFLAGS) $(WXBASE_CPPFLAGS) -I$(srcdir)/libs -I$(srcdir)/include $(CRYPTOPP_CPPFLAGS) $(LIBUPNP_CPPFLAGS)
118 # Common to gui/monolithic
120 libmuleappgui_a_SOURCES = \
123 EditServerListDlg.cpp \
124 extern/wxWidgets/listctrl.cpp \
125 FileDetailListCtrl.cpp \
135 libmuleappgui_a_CPPFLAGS = $(AM_CPPFLAGS) $(WX_CPPFLAGS) -I$(srcdir)/libs -I$(srcdir)/include $(LIBUPNP_CPPFLAGS) $(GEOIP_CPPFLAGS)
140 CanceledFileList.cpp \
142 ClientCreditsList.cpp \
143 ClientTCPSocket.cpp \
144 ClientUDPSocket.cpp \
145 CorruptionBlackBox.cpp \
148 ECSpecialCoreTags.cpp \
150 EncryptedStreamSocket.cpp \
151 EncryptedDatagramSocket.cpp \
163 ServerUDPSocket.cpp \
167 UploadBandwidthThrottler.cpp \
170 kademlia/kademlia/Indexed.cpp \
171 kademlia/kademlia/Kademlia.cpp \
172 kademlia/kademlia/Prefs.cpp \
173 kademlia/kademlia/Search.cpp \
174 kademlia/kademlia/UDPFirewallTester.cpp \
175 kademlia/net/KademliaUDPListener.cpp \
176 kademlia/net/PacketTracking.cpp \
177 kademlia/routing/Contact.cpp \
178 kademlia/routing/RoutingZone.cpp
189 CommentDialogLst.cpp \
190 GenericClientListCtrl.cpp \
191 ClientDetailDialog.cpp \
192 DirectoryTreeCtrl.cpp \
193 FileDetailDialog.cpp \
196 PrefsUnifiedDlg.cpp \
202 DownloadListCtrl.cpp \
204 SharedFilePeersListCtrl.cpp \
207 SharedFilesCtrl.cpp \
216 ECSpecialMuleTags.cpp \
232 core_libs = -L. -lmuleappcore $(LIBUPNP_LDFLAGS) $(LIBUPNP_LIBS)
233 gui_libs = -L. -lmuleappgui $(WX_LIBS) $(GEOIP_LDFLAGS) $(GEOIP_LIBS)
234 remote_common_libs = -Llibs/common -Llibs/ec/cpp -lmulecommon -lec $(BFD_LIBS) $(ZLIB_LDFLAGS) $(ZLIB_LIBS) $(RESOLV_LIB)
235 common_libs = -L. -lmuleappcommon $(remote_common_libs) -lmulesocket $(BOOST_SYSTEM_LDFLAGS) $(BOOST_SYSTEM_LIBS) $(CRYPTOPP_LDFLAGS) $(CRYPTOPP_LIBS)
237 core_deps = libmuleappcore.a
238 gui_deps = libmuleappgui.a
239 remote_common_deps = libs/common/libmulecommon.a libs/ec/cpp/libec.a
240 common_deps = libmuleappcommon.a $(remote_common_deps) libmulesocket.a
243 core_libs += -lshlwapi
249 core_flags = $(LIBUPNP_CPPFLAGS) $(LIBUPNP_CFLAGS)
250 gui_flags = $(WX_CPPFLAGS) $(GEOIP_CPPFLAGS)
251 common_flags = -I$(srcdir)/libs -Ilibs -I$(srcdir)/include $(CRYPTOPP_CPPFLAGS)
253 # --------- Apps ---------
256 amule-remote-gui.cpp \
263 CaptchaGenerator.cpp \
264 PartFileConvert.cpp \
265 PartFileConvertDlg.cpp \
277 amule_DEPENDENCIES = $(common_deps) $(core_deps) $(gui_deps)
278 amule_CPPFLAGS = $(AM_CPPFLAGS) $(core_flags) $(gui_flags) $(common_flags)
279 amule_CXXFLAGS = $(AM_CXXFLAGS) $(WX_CFLAGS_ONLY) $(WX_CPPFLAGS_ONLY)
280 amule_LDADD = $(common_libs) $(core_libs) $(gui_libs)
282 amulegui_DEPENDENCIES = $(common_deps) $(gui_deps)
283 amulegui_CPPFLAGS = $(AM_CPPFLAGS) $(gui_flags) $(common_flags) -DCLIENT_GUI
284 amulegui_CXXFLAGS = $(AM_CXXFLAGS) $(WX_CFLAGS_ONLY) $(WX_CXXFLAGS_ONLY)
285 amulegui_LDADD = $(common_libs) $(gui_libs)
287 amuled_DEPENDENCIES = $(core_deps) $(common_deps)
288 amuled_CPPFLAGS = $(AM_CPPFLAGS) $(WXBASE_CPPFLAGS) $(core_flags) $(common_flags) -DAMULE_DAEMON
289 amuled_CXXFLAGS = $(AM_CXXFLAGS) $(WX_CFLAGS_ONLY) $(WX_CXXFLAGS_ONLY)
290 amuled_LDADD = $(common_libs) $(core_libs) $(WXBASE_LIBS)
297 ed2k_CPPFLAGS = $(AM_CPPFLAGS) -DUSE_STD_STRING
301 ed2k_LDADD = -lshlwapi
305 ed2k_LDFLAGS = $(AM_LDFLAGS) -framework CoreServices
310 ExternalConnector.cpp \
315 amulecmd_DEPENDENCIES = $(remote_common_deps) libmulesocket.a
316 amulecmd_CPPFLAGS = $(AM_CPPFLAGS) $(WXBASE_CPPFLAGS) $(common_flags)
317 amulecmd_CXXFLAGS = $(AM_CXXFLAGS) $(WX_CFLAGS_ONLY) $(WX_CXXFLAGS_ONLY)
318 #amulecmd_LDADD = $(WXBASE_LIBS) $(READLINE_LIBS) $(remote_common_libs)
319 amulecmd_LDADD = -Llibs/common -Llibs/ec/cpp -L. -lmulecommon -lec -lmulesocket \
320 $(WXBASE_LIBS) $(READLINE_LIBS) $(BFD_LIBS) $(ZLIB_LDFLAGS) $(ZLIB_LIBS) $(RESOLV_LIB) $(BOOST_SYSTEM_LDFLAGS) $(BOOST_SYSTEM_LIBS)
340 ClientCreditsList.h \
341 ClientDetailDialog.h \
342 SharedFilePeersListCtrl.h \
351 CorruptionBlackBox.h \
355 DirectoryTreeCtrl.h \
359 EditServerListDlg.h \
361 EncryptedDatagramSocket.h \
362 EncryptedStreamSocket.h \
363 ExternalConnector.h \
368 FileDetailListCtrl.h \
375 GenericClientListCtrl.h \
411 PartFileConvertDlg.h \
447 TerminationProcess.h \
448 TerminationProcessAmuleweb.h \
458 UploadBandwidthThrottler.h \
461 UPnPCompatibility.h \
463 extern/wxWidgets/listctrl.h
465 MAINTAINERCLEANFILES = Makefile.in
467 $(srcdir)/Parser.cpp: Parser.y
468 bison --debug -t -d -v -o $@ $(srcdir)/Parser.y
470 if GENERATE_FLEX_HEADER
471 $(srcdir)/Scanner.cpp: Scanner.l Parser.cpp
472 $(LEX) --header-file=$(srcdir)/Scanner.h -o $@ $(srcdir)/Scanner.l
474 $(srcdir)/Scanner.cpp: Scanner.l Parser.cpp
475 $(LEX) -o $@ $(srcdir)/Scanner.l; \
476 echo "// Empty file generated by a flex version unable to create headers" > $(srcdir)/Scanner.h
479 $(srcdir)/IPFilterScanner.cpp: IPFilterScanner.l
480 $(LEX) -Pyyip -o $@ $(srcdir)/IPFilterScanner.l;
489 $(RC) $(MULERCFLAGS) -I$(top_srcdir) $(RCFLAGS) -O COFF -i "$<" -o "$@"
491 nodist_amuled_SOURCES = amuled-version.rc
492 nodist_amulecmd_SOURCES = amulecmd-version.rc
493 nodist_ed2k_SOURCES = ed2k-version.rc
494 amule_LDADD += amulerc.$(OBJEXT)
495 amule_DEPENDENCIES += amulerc.$(OBJEXT)
496 amulegui_LDADD += amuleguirc.$(OBJEXT)
497 amulegui_DEPENDENCIES += amuleguirc.$(OBJEXT)
499 amulerc.$(OBJEXT): $(srcdir)/../amule.rc amule-version.rc
502 abs_builddir=`pwd` ; \
503 abs_top_srcdir=`cd $(top_srcdir) ; pwd` ; \
505 $(RC) $(MULERCFLAGS) -I$${abs_top_srcdir} $(RCFLAGS) -O COFF -o "$${abs_builddir}/$@" ; \
508 amuleguirc.$(OBJEXT): $(srcdir)/../amule.rc amulegui-version.rc
511 abs_builddir=`pwd` ; \
512 abs_top_srcdir=`cd $(top_srcdir) ; pwd` ; \
514 $(RC) $(MULERCFLAGS) -I$${abs_top_srcdir} $(RCFLAGS) -O COFF -o "$${abs_builddir}/$@" ; \
517 amule-version.rc: $(top_builddir)/version.rc
518 @sed -e 's/VER_FILEDESCRIPTION_STR/"All-Platform P2P Client Based on eMule"/' \
519 -e 's/VER_INTERNALNAME_STR/"amule"/' \
520 -e 's/VER_ORIGINALFILENAME_STR/"amule$(EXEEXT)"/' "$<" > "$@"
522 amuled-version.rc: $(top_builddir)/version.rc
523 @sed -e 's/VER_FILEDESCRIPTION_STR/"aMule Daemon"/' \
524 -e 's/VER_INTERNALNAME_STR/"amuled"/' \
525 -e 's/VER_ORIGINALFILENAME_STR/"amuled$(EXEEXT)"/' "$<" > "$@"
527 amulecmd-version.rc: $(top_builddir)/version.rc
528 @sed -e 's/VER_FILEDESCRIPTION_STR/"aMule Text Client"/' \
529 -e 's/VER_INTERNALNAME_STR/"amulecmd"/' \
530 -e 's/VER_ORIGINALFILENAME_STR/"amulecmd$(EXEEXT)"/' "$<" > "$@"
532 amulegui-version.rc: $(top_builddir)/version.rc
533 @sed -e 's/VER_FILEDESCRIPTION_STR/"aMule Remote GUI (Experimental)"/' \
534 -e 's/VER_INTERNALNAME_STR/"amulegui"/' \
535 -e 's/VER_ORIGINALFILENAME_STR/"amulegui$(EXEEXT)"/' "$<" > "$@"
537 ed2k-version.rc: $(top_builddir)/version.rc
538 @sed -e 's/VER_FILEDESCRIPTION_STR/"ED2K Links Handler"/' \
539 -e 's/VER_INTERNALNAME_STR/"ed2k"/' \
540 -e 's/VER_ORIGINALFILENAME_STR/"ed2k$(EXEEXT)"/' "$<" > "$@"
542 CLEANFILES = *-version.rc
547 EXTRA__DIST__SUBDIRS = include kademlia
548 include $(top_srcdir)/automake/dist-hook.am