forked from osmocom/wireshark
![Bill Meier](/assets/img/avatar_default.png)
- Define macros for certain CFLAGS in config.nmake iso of having defs in each makefile; a. -DHAVE_CONFIG_H and -D_U_="" are now part of a macro named STANDARD_CFLAGS; b. -WX has been replaced by WARNINGS_ARE_ERRORS (defined as -WX in config.nmake) (This allows disabling "Warnings as Errors" by just changing config.nmake) c. CVARSDLL definitions (not usage) have been removed from the various makefiles. XXX: It appears the usage of CVARSDLL can also be removed (not yet done) since: -DWIN32 and -DNULL=0 do not appear to be needed (any more); -D_MT and _D_DLL are not needed since /MP causes these definitions. d. Define a macro WARNINGS_CFLAGS with additional specific compiler (level4) warnings to be enabled. E.G., 4295: array is too small to include a terminating null character - config.nmake: reformat some long lines for readability; - plugins\Makefile.nmake: clean-deps does nothing: remove it (and usage in top-level makefile); - dissectors/Makefile.nmake: test to enable packet-rrc.obj target needs to include MSVC2010 ... svn path=/trunk/; revision=35747
69 lines
1.6 KiB
Makefile
69 lines
1.6 KiB
Makefile
# Makefile.nmake
|
|
# nmake file for codec_test plugin
|
|
#
|
|
# $Id$
|
|
#
|
|
|
|
include ..\..\config.nmake
|
|
include moduleinfo.nmake
|
|
|
|
include Makefile.common
|
|
|
|
CFLAGS=$(WARNINGS_ARE_ERRORS) $(STANDARD_CFLAGS) \
|
|
/I../.. $(GLIB_CFLAGS) \
|
|
/I$(PCAP_DIR)\include
|
|
|
|
CPPFLAGS = $(CFLAGS) -TP
|
|
|
|
.c.obj::
|
|
$(CC) $(CPPFLAGS) -Fd$(PLUGIN_NAME).pdb -c $<
|
|
|
|
LDFLAGS = $(PLUGIN_LDFLAGS)
|
|
|
|
!IFDEF ENABLE_LIBWIRESHARK
|
|
LINK_PLUGIN_WITH=..\..\epan\libwireshark.lib
|
|
CFLAGS=/D_NEED_VAR_IMPORT_ $(CFLAGS)
|
|
|
|
CODEC_OBJECTS = $(CODEC_SRC:.c=.obj)
|
|
|
|
CODEC_LIBS = \
|
|
EasyG729A/EasyG729A.lib \
|
|
EasyG7231/EasyG7231.lib \
|
|
EasyG722/EasyG722.lib
|
|
|
|
OBJECTS=$(CODEC_OBJECTS)
|
|
|
|
RESOURCE=$(PLUGIN_NAME).res
|
|
|
|
all: $(PLUGIN_NAME).dll
|
|
|
|
$(PLUGIN_NAME).rc : moduleinfo.nmake
|
|
sed -e s/@PLUGIN_NAME@/$(PLUGIN_NAME)/ \
|
|
-e s/@RC_MODULE_VERSION@/$(RC_MODULE_VERSION)/ \
|
|
-e s/@RC_VERSION@/$(RC_VERSION)/ \
|
|
-e s/@MODULE_VERSION@/$(MODULE_VERSION)/ \
|
|
-e s/@PACKAGE@/$(PACKAGE)/ \
|
|
-e s/@VERSION@/$(VERSION)/ \
|
|
-e s/@MSVC_VARIANT@/$(MSVC_VARIANT)/ \
|
|
< plugin.rc.in > $@
|
|
|
|
$(PLUGIN_NAME).dll $(PLUGIN_NAME).exp $(PLUGIN_NAME).lib : $(OBJECTS) $(LINK_PLUGIN_WITH) $(RESOURCE)
|
|
link -dll /out:$(PLUGIN_NAME).dll $(LDFLAGS) $(OBJECTS) $(LINK_PLUGIN_WITH) \
|
|
$(GLIB_LIBS) $(CODEC_LIBS) $(RESOURCE)
|
|
|
|
easy_codec_plugin.obj : easy_codec_plugin.c
|
|
$(CC) $(CFLAGS) -Fd$(PLUGIN_NAME).pdb -c easy_codec_plugin.c
|
|
|
|
!ENDIF
|
|
|
|
clean:
|
|
rm -f $(OBJECTS) $(PLUGIN_NAME).dll $(PLUGIN_NAME).dll.manifest $(PLUGIN_NAME).exp \
|
|
$(RESOURCE) $(PLUGIN_NAME).rc $(PLUGIN_NAME).lib *.pdb
|
|
|
|
distclean: clean
|
|
|
|
maintainer-clean: distclean
|
|
|
|
checkapi:
|
|
$(PERL) ../../tools/checkAPIs.pl -g abort -g termoutput $(DISSECTOR_SRC) $(DISSECTOR_INCLUDES)
|