Wireshark-dev: [Wireshark-dev] Building wireshark-0.99.8-SVN-23860 fails due to uncreated direc
From: "J.C. Wren" <jcwren@xxxxxxxxx>
Date: Fri, 14 Dec 2007 12:45:12 -0500
Building under Windows, when the Makefile.nmake got to the following
step, it failed.  The plugins directory had not created prior to it
attempting to create the 0.99.8-SVN-23860 directory.  The patch I
applied to the ./Makefile.nmake is below.

        if not exist wireshark-gtk1\wimaxasncp mkdir wireshark-gtk1\wimaxasncp
        xcopy ".\wimaxasncp\*.*" wireshark-gtk1\wimaxasncp /d
.\wimaxasncp\dictionary.dtd
.\wimaxasncp\dictionary.xml
2 File(s) copied
        if not exist wireshark-gtk1\plugins\0.99.8-SVN-23860 mkdir
wireshark-gtk1\plugins\0.99.8-SVN-23860
4NT: The system cannot find the path specified.
 "C:\wireshark\wireshark-gtk1\plugins\0.99.8-SVN-23860"
NMAKE : fatal error U1077: 'if' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\PROGRAM FILES\MICROSOFT VISUAL STUDIO
8\VC\BIN\NMAKE.EXE"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\PROGRAM FILES\MICROSOFT VISUAL STUDIO
8\VC\BIN\NMAKE.EXE"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\PROGRAM FILES\MICROSOFT VISUAL STUDIO
8\VC\BIN\NMAKE.EXE"' : return code '0x2'
Stop.

[c:\wireshark]

$ diff -u Makefile.nmake.org Makefile.nmake
--- Makefile.nmake.org  2007-12-14 12:42:31.890625000 -0500
+++ Makefile.nmake      2007-12-14 12:42:57.062500000 -0500
@@ -921,6 +921,7 @@
        xcopy ".\tpncp\*.dat" $(INSTALL_DIR)\tpncp /d
        if not exist $(INSTALL_DIR)\wimaxasncp mkdir $(INSTALL_DIR)\wimaxasncp
        xcopy ".\wimaxasncp\*.*" $(INSTALL_DIR)\wimaxasncp /d
+       if not exist $(INSTALL_DIR)\plugins mkdir $(INSTALL_DIR)\plugins
        if not exist $(INSTALL_DIR)\plugins\$(VERSION) mkdir
$(INSTALL_DIR)\plugins\$(VERSION)
        xcopy ".\plugins\agentx\agentx.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d
        xcopy ".\plugins\artnet\artnet.dll" $(INSTALL_DIR)\plugins\$(VERSION) /d


Of course, 'mkdir' on a *real* OS would support a -p option.