Skip to content

Commit

Permalink
wmake: do bootstrap wmake build more portable
Browse files Browse the repository at this point in the history
  • Loading branch information
jmalak committed Mar 17, 2024
1 parent 66bff64 commit 2e72a3b
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 7 deletions.
12 changes: 11 additions & 1 deletion bld/wmake/wmake
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
!ifdef __DOS__
bld_os = dos
!else ifdef __NT__
bld_os = nt
!else ifdef __OS2__
bld_os = os2
!else ifdef __LINUX__
bld_os = linux
!endif

link_sys_dos = causeway
link_sys_os2 = os2v2

Expand Down Expand Up @@ -25,7 +35,7 @@ objs = &
!endif

.c.obj : .AUTODEPEND
*wcc386 -zq -D_BLDVER=$(bld_ver_tool) -D_CYEAR=$(curr_year) -DBOOTSTRAP -w8-we-s-oaxt-j-fpc-zc -d2 -bt=$(bld_os) -I. -I"../h" -I"../../lib_misc/h" -I"../../watcom/h" -fo="$@" "$<"
*wcc386 -zq -D_BLDVER=$(%OWBLDVERTOOL) -D_CYEAR=xxxx -DBOOTSTRAP -w8-we-s-oaxt-j-fpc-zc -d2 -bt=$(bld_os) -I. -I"../h" -I"../../lib_misc/h" -I"../../watcom/h" -fo="$@" "$<"

./wsplice.exe : wsplice.obj
*wlink name $@ op q, map sys $(link_sys) file {$<}
Expand Down
4 changes: 2 additions & 2 deletions build.bat
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ cd "%OWOBJDIR%"
if exist "%OWROOT%\build\%OWOBJDIR%\wmake.exe" del "%OWROOT%\build\%OWOBJDIR%\wmake.exe"
if '%OWTOOLS%' == 'VISUALC' goto visualc
if '%OWTOOLS%' == 'INTEL' goto intel
wmake -f ..\wmake clean >>"%OWBUILDER_BOOTX_OUTPUT%" %OWBUILDER_REDIR_ERROUT%
wmake -f ..\wmake >>"%OWBUILDER_BOOTX_OUTPUT%" %OWBUILDER_REDIR_ERROUT%
wmake -m -f ..\wmake clean >>"%OWBUILDER_BOOTX_OUTPUT%" %OWBUILDER_REDIR_ERROUT%
wmake -m -f ..\wmake >>"%OWBUILDER_BOOTX_OUTPUT%" %OWBUILDER_REDIR_ERROUT%
if errorlevel == 1 goto exiterr
goto mkbuilder
:intel
Expand Down
4 changes: 2 additions & 2 deletions build.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ cd %OWROOT%\bld\wmake
if not exist %OWOBJDIR% mkdir %OWOBJDIR%
cd %OWOBJDIR%
if exist %OWROOT%\build\%OWOBJDIR%\wmake.exe del %OWROOT%\build\%OWOBJDIR%\wmake.exe
wmake -f ..\wmake clean >>%OWBUILDER_BOOTX_OUTPUT% 2>&1
wmake -f ..\wmake >>%OWBUILDER_BOOTX_OUTPUT% 2>&1
wmake -m -f ..\wmake clean >>%OWBUILDER_BOOTX_OUTPUT% 2>&1
wmake -m -f ..\wmake >>%OWBUILDER_BOOTX_OUTPUT% 2>&1
if errorlevel == 1 goto error_exit
cd %OWROOT%\bld\builder
if not exist %OWOBJDIR% mkdir %OWOBJDIR%
Expand Down
4 changes: 2 additions & 2 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ if [ ! -d $OWOBJDIR ]; then mkdir $OWOBJDIR; fi
cd $OWOBJDIR
rm -f ../../../build/$OWOBJDIR/wmake
if [ "$OWTOOLS" = "WATCOM" ]; then
output_redirect wmake -f ../wmake clean
output_redirect wmake -f ../wmake
output_redirect wmake -m -f ../wmake clean
output_redirect wmake -m -f ../wmake
else
case `uname` in
FreeBSD)
Expand Down

0 comments on commit 2e72a3b

Please sign in to comment.