DEB_DIR = Debug
-!ifndef MAKE_TYPE
!ifndef NLMSDKBASE
!message "Run bat\SetNWBld.bat to set the NetWare SDK before continuing.\n"
!error
BS_CFLAGS = -opt off -inline off -sym on -sym codeview4 -sym internal -DDEBUGGING -DDKFBPON
BLDMESG = $(BLDMESG) Using /d2 option
!ifdef NLM_NAME8
-LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(NLM_NAME8).sym
+LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(MAKE_TYPE)\$(NLM_NAME8).sym
!else # !ifdef NLM_NAME8
-LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(NLM_NAME).sym
+LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(MAKE_TYPE)\$(NLM_NAME).sym
!endif # !ifdef NLM_NAME8
!else # !ifdef USE_D2
BS_CFLAGS = -opt off -inline off -sym on -sym codeview4 -sym internal -DDEBUGGING -DDKFBPON
BLDMESG = $(BLDMESG) Using /d1 option
!ifdef NLM_NAME8
-LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(NLM_NAME8).sym
+LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(MAKE_TYPE)\$(NLM_NAME8).sym
!else # !ifdef NLM_NAME8
-LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(NLM_NAME).sym
+LDFLAGS = $(LDFLAGS) -sym on -sym codeview4 -sym internal -osym $(MAKE_TYPE)\$(NLM_NAME).sym
!endif # !ifdef NLM_NAME8
!endif # !ifdef USE_D2
!else # !if "$(MAKE_TYPE)"=="Debug"
@echo $(MPKMESSAGE)...$(BLDMESG)...$@
$(C_COMPILER) $(COMPLER_FLAGS) $(NLM_INCLUDES) -I..\x2p $(ADD_LOCDEFS) $(ERROR_FLAG) $*.c -o $@
@echo Built $(@)
-
+
..\x2p\hash$(o) : ..\x2p\hash.c
@echo $(MPKMESSAGE)...$(BLDMESG)...$@
$(C_COMPILER) $(COMPLER_FLAGS) $(NLM_INCLUDES) -I..\x2p $(ADD_LOCDEFS) $(ERROR_FLAG) $*.c -o $@
$(MINIPERL) -I..\lib ..\splittree.pl "../LIB" $(AUTODIR)
@echo ========Linked $@ ==========
-!if "$(MAKE_TYPE)"=="Debug"
-!ifdef NLM_NAME8
- .\bat\cvpack $(BLDDIR)\$(NLM_NAME8).sym
-!else
- .\bat\cvpack $(BLDDIR)\$(NLM_NAME).sym
-!endif
-!endif
-
@echo======= Finished building $(BUILT).
# Create the debug or release directory if not existing
@if exist .\config.h del /f /q .\config.h
@if exist .\config.nw5 del /f /q .\config.nw5
@if exist .\perl.imp del /f /q .\perl.imp
- -del /f /q *.obj *.lib *.def *.sym *.map *.xdc *.err
+ -del /f /q *.obj *.lib *.def *.sym *.map *.xdc *.err *.nlm
cd testnlm\echo
- -del /f /q *.obj *.map *.link *.options *.nlm *.sym *.xdc *.err
+ -del /f /q *.obj *.map *.link *.options *.nlm *.sym *.xdc *.err *.lib *.def *.pdb *.bs
cd ..\type
- -del /f /q *.obj *.map *.link *.options *.nlm *.sym *.xdc *.err
+ -del /f /q *.obj *.map *.link *.options *.nlm *.sym *.xdc *.err *.lib *.def *.pdb *.bs
cd ..\..\
utils: $(BLDDIR)\$(NLM_NAME8).$(NLM_EXT) $(X2P)
-del /f /q $(CONFIGPM)
-del /f /q bin\*.bat
cd $(EXTDIR)
- -del /s /f /q *.lib *.def *.map *.pdb *.bs Makefile *$(o) pm_to_blib *.xdc *.err
+ -del /s /q /f *.lib *.def *.map *.pdb *.bs Makefile *$(o) pm_to_blib *.xdc *.err *.obj *.sym
cd ..\netware
!if "$(NW_EXTNS)"=="yes"
cd cgi2perl
- -del /f /q *.obj *.bs Makefile *$(o) *.c pm_to_blib *.xdc *.err *.sym *.map
+ -del /f /q *.obj *.bs Makefile *$(o) *.c pm_to_blib *.xdc *.err *.sym *.map *.def *.lib *.pdb
cd ..
cd $(EXTDIR)\Perl2UCS
- -del /f /q *.obj *.bs Makefile *$(o) *.c pm_to_blib *.xdc *.err *.sym *.map *.c
+ -del /f /q *.obj *.bs Makefile *$(o) *.c pm_to_blib *.xdc *.err *.sym *.map *.def *.lib *.pdb
cd ..\..\netware
cd $(EXTDIR)\UCSExt
-del /f /q *.obj *.bs Makefile *$(o) *.c pm_to_blib *.xdc *.err *.sym *.map *.c
strcpy(pclp->m_argv[pclp->m_argc], new_arg); // Appended the new argument.
pclp->m_argc++; // Increment the number of parameters appended.
- // The char array is emptied for all elements upto the end so that there are no junk characters.
- // If this is not done, then the issue is like this:
+ // The char array is emptied for all elements upto the end so that there are no
+ // junk characters. If this is not done, then the issue is like this:
// - Simple perl command like "perl" on the system console works fine for the first time.
- // - When it is given the second time, a new blank screen should come up which also
- // allows for editing. This was not consistently working well.
- // More so when the command was like, "perl ", that is the name "perl"
- // followed by a few blank spaces. It used to give error in opening file and
- // would give some junk as the filename unable to open.
- // Once the below fix was done, it is working fine.
+ // - When "perl" is executed the second time, a new blank screen should come up
+ // which allows for editing also. This was not consistently working well.
+ // More so when the command was like, "perl ", that is the name "perl" followed
+ // by a few blank spaces, it used to give error in opening file:
+ // "unable to open the file" since the filename would have some junk characters.
+ //
+ // These issues are fixed through the code below.
for(i=pclp->m_argc; i<pclp->m_argv_len; i++)
strncpy(pclp->m_argv[i], "", (MAX_DN_BYTES * sizeof(char))); // MAX_DN_BYTES is the size of pclp->m_argv[].
if "%1" == "d" goto set_type_dbg
if "%1" == "D" goto set_type_dbg
-Rem Invalid input, display help message
+Rem Invalid input and so display the help message
goto Usage
:set_type_rel
:now
if "%MAKE_TYPE%" == "" echo MAKE_TYPE is not set, hence it defaults to Release build
-if not "%MAKE_TYPE%" == "" echo Current build type is - %MAKE_TYPE%
+if not "%MAKE_TYPE%" == "" echo Current build type is - %MAKE_TYPE%
call ToggleD2 /now
goto exit
:Usage
@echo on
@echo "Usage: buildtype r/R|d/D [on/off]"
- @echo on/off - Toggling D2 flag for debug build
+ @echo on/off - Toggling only for D2 flag during debug build
@echo "Usage: buildtype /now" - To display current setting
@echo Ex. buildtype d on
@echo Ex. setCodeWar d:\CodeWar
:exit
-@echo off\r
-@rem AUTHOR: sgp & apc\r
-@rem CREATED: 24th July 2000\r
-@rem LAST REVISED: 6th April 2001\r
-@rem LAST REVISED: 22nd May 2002\r
-@rem AUTHOR: apc\r
-@rem Batch file to set the path to CodeWarrior directories\r
-@rem This file is called from SetNWBld.bat.\r
-\r
-if "%1" == "/now" goto now\r
-if "%1" == "" goto Usage\r
-if "%1" == "/?" goto usage\r
-if "%1" == "/h" goto usage\r
-\r
-set CODEWAR=%1\r
-ECHO CODEWAR=%1\r
-\r
-call buildtype r\r
-@echo Buildtype set to Release type\r
-\r
-set MWCIncludes=%1\include\r
-@echo MWCIncludes=%1\include\r
-set MWLibraries=%1\lib\r
-@echo MWLibraries=%1\lib\r
-set MWLibraryFiles=%1\lib\nwpre.obj;%1\lib\mwcrtld.lib\r
-@echo MWLibraryFiles=%1\lib\nwpre.obj;%1\lib\mwcrtld.lib\r
-\r
-set PATH=%PATH%;%1\bin;\r
-@echo PATH=%PATH%;%1\bin;\r
-\r
-goto exit\r
-\r
-:now\r
-@echo CODEWAR=%CODEWAR%\r
-goto exit\r
-\r
-:Usage\r
- @echo on\r
- @echo "Usage: setCodeWar <Path to CodeWarrior binaries>"\r
- @echo "Usage: setCodeWar /now" - To display current setting\r
- @echo Ex. setCodeWar d:\CodeWar\r
-\r
-:exit\r
@echo off
-@rem AUTHOR: sgp
+@rem AUTHOR: apc
@rem CREATED: Thu 18th Jan 2001 09:18:08
@rem LAST REVISED: 6th April 2001
-@rem Batch file to set the path to NetWare SDK, Watcom directories & MPK SDK
-@rem This file calls setnlmsdk.bat, setwatcom.bat & setmpksdk.bat
+@rem LAST REVISED: 22nd May 2002
+@rem Batch file to set the path to Default Buildtype,NetWare SDK, CodeWarrior directories
+@rem This file calls buildtype with release as defualt,setnlmsdk.bat, setCodeWar.bat & setmpksdk.bat and MpkBuild with off as default
REM If no parameters are passed, display usage
if "%1" == "" goto Usage
REM If na is passed, don't set that parameter
if "%1" == "na" goto skip_nlmsdk_msg
+
:setnwsdk
call setnlmsdk %1
goto skip_nlmsdk_nomsg
:skip_nlmsdk_msg
@echo Retaining NLMSDKBASE=%NLMSDKBASE%
-:skip_nlmsdk_nomsg
-if "%2" == "" goto exit
-if "%2" == "na" goto skip_watcom_msg
-:setwatcom
-call setwatcom %2
-goto skip_watcom_nomsg
-
-:skip_watcom_msg
-@echo Retaining WATCOM=%WATCOM%
-:skip_watcom_nomsg
+:skip_nlmsdk_nomsg
+if "%2" == "" goto err_exit
+if "%2" == "na" goto skip_cw_msg
-if "%3" == "" goto exit
-if "%3" == "na" goto skip_mpksdk_msg
-:setmpk
-call setmpksdk %3
-goto skip_mpksdk_nomsg
+:setcodewar
+call setcodewar %2
+goto skip_cw_nomsg
-:skip_mpksdk_msg
-@echo Retaining MPKBASE=%MPKBASE%
-:skip_mpksdk_nomsg
+:skip_cw_msg
+@echo Retaining CODEWAR=%CODEWAR%
+goto exit
+:skip_cw_nomsg
goto exit
+:err_exit
+@echo Not Enough Parameters
+goto Usage
+
:now
@echo NLMSDKBASE=%NLMSDKBASE%
-@echo WATCOM=%WATCOM%
-@echo MPKBASE=%MPKBASE%
+@echo CODEWAR=%CODEWAR%
goto exit
-goto exit
:Usage
@echo on
- @echo "Usage: setnwbld <path to NetWare SDK> [<path to Watcom dir>] [<path to MPK SDK>]"
- @echo "Usage: setnwbld /now" - To display current setting
+ @echo "Usage: setnwdef <path to NetWare SDK> <path to CodeWarrior dir>"
+ @echo "Usage: setnwdef /now" - To display current setting
@echo Pass na if you don't want to change a setting
- @echo Ex. setnwbld d:\ndk\nwsdk na p:\mpk
- @echo Ex. setnwbld d:\ndk\
+ @echo Ex. setnwbld d:\ndk\nwsdk na
+ @echo Ex. setnwbld na d:\codewar
+
:exit
@echo "Usage: setnlmsdk <path to NetWare sdk>"
@echo "Usage: setnlmsdk /now" - To display current setting
@echo Ex. setnlmsdk e:\sdkcd14\nwsdk
-:exit
+:exit
if "%1" == "off" goto no
if "%1" == "/?" goto usage
if "%1" == "/h" goto usage
-goto dontknow
+
+Rem Invalid input and so display the help message
+goto Usage
:now
if "%USE_D2%" == "" echo USE_D2 is removed, uses /d1
echo ....USE_D2 is removed. uses /d1
goto exit
-:dontknow
-goto Usage
-
:Usage
@echo on
@echo "Usage: ToggleD2 [on|off]"
@echo "Usage: ToggleD2 /now" - To display current setting
+
:exit
# These scripts have problems (either abend or hang) as of now (11 May 2001).
# So, they are commented out in the corresponding auto scripts, io.pl and lib.pl
-@ScriptsNotUsed = ("t/io/openpid.t", "t/lib/filehandle.t", "t/lib/memoize/t/expire_module_t.t", "t/lib/NEXT/t/next.t", "t/lib/Math/BigInt/t/require.t", "t/ext/B/t/debug.t","t/lib/IPC/Open3.t", "t/ext/B/t/showlex.t", "t/op/subst_wamp.t", "t/uni/upper.t", "t/lib/Net/t/ftp.t");
+@ScriptsNotUsed = ("t/io/openpid.t", "t/lib/filehandle.t", "t/lib/memoize/t/expire_module_t.t", "t/lib/NEXT/t/next.t", "t/lib/Math/BigInt/t/require.t", "t/ext/B/t/debug.t","t/lib/IPC/Open3.t", "t/ext/B/t/showlex.t", "t/op/subst_wamp.t", "t/uni/upper.t", "t/lib/Net/t/ftp.t", "t/op/sort.t, ", "t/ext/POSIX/t/posix.t");
opendir(DIR, $DirName);
@Dirs = readdir(DIR);
#ifdef VMS
# include "config.h"
+#elif defined(NETWARE)
+# include "../NetWare/config.h"
#else
# include "../config.h"
#endif