1 ## Use: $(MAKE) /$(MAKEFLAGS) -f makefile.nmake
\r
3 # $Id: Makefile.nmake 13077 2005-01-16 23:26:02Z lroland $
\r
5 include ../../config.nmake
\r
7 UNIX2DOS=$(PERL) ../../tools/unix2dos.pl
\r
10 DISSECTOR_FILES=packet-$(PROTOCOL_NAME).c packet-$(PROTOCOL_NAME).h
\r
12 all: generate_dissector
\r
14 generate_dissector: $(DISSECTOR_FILES)
\r
16 $(DISSECTOR_FILES): ../../tools/asn2eth.py Lightweight-Directory-Access-Protocol-V3.asn packet-ldap-template.c packet-ldap-template.h ldap.cnf
\r
18 $(PYTHON) ../../tools/asn2eth.py -X -b -e -p $(PROTOCOL_NAME) -c ldap.cnf -s packet-ldap-template Lightweight-Directory-Access-Protocol-V3.asn
\r
20 @echo Error: You need Python to use asn2eth.py
\r
25 rm -f parsetab.py $(DISSECTOR_FILES)
\r
27 # Fix EOL in generated dissectors. Cygwin's python generates files with
\r
28 # mixed EOL styles, which can't be commited to the SVN repository.
\r
29 # Stuff included from template and "cnf" files has "\r\n" on windows, while
\r
30 # the generated stuff has "\n".
\r
32 fix_eol: generate_dissector
\r
33 move packet-$(PROTOCOL_NAME).c packet-$(PROTOCOL_NAME).c.tmp
\r
34 move packet-$(PROTOCOL_NAME).h packet-$(PROTOCOL_NAME).h.tmp
\r
35 $(UNIX2DOS) < packet-$(PROTOCOL_NAME).c.tmp > packet-$(PROTOCOL_NAME).c
\r
36 $(UNIX2DOS) < packet-$(PROTOCOL_NAME).h.tmp > packet-$(PROTOCOL_NAME).h
\r
37 del /f packet-$(PROTOCOL_NAME).c.tmp packet-$(PROTOCOL_NAME).h.tmp
\r
39 copy_files: generate_dissector fix_eol
\r
40 xcopy packet-$(PROTOCOL_NAME).c ..\..\epan\dissectors /d /y
\r
41 xcopy packet-$(PROTOCOL_NAME).h ..\..\epan\dissectors /d /y
\r