diff options
author | Pedro Giffuni <pfg@apache.org> | 2011-11-08 18:34:15 +0000 |
---|---|---|
committer | Pedro Giffuni <pfg@apache.org> | 2011-11-08 18:34:15 +0000 |
commit | 9fdf4cc25ed37566e463fb465abc1691952a3298 (patch) | |
tree | ee71a7f23549e48d9717f628d09567c54c984fa9 /dmake | |
parent | d06280df855c762ceaa58c59b3832196fb4cf6a0 (diff) |
i118582: OS/2 port - support building dmake with klibc. By Yuri Dario.
Diffstat (limited to 'dmake')
-rw-r--r-- | dmake/imacs.c | 2 | ||||
-rwxr-xr-x | dmake/make.cmd | 33 | ||||
-rw-r--r-- | dmake/sysintf.c | 2 |
3 files changed, 21 insertions, 16 deletions
diff --git a/dmake/imacs.c b/dmake/imacs.c index 437a2a53c8a6..4b30f2803d52 100644 --- a/dmake/imacs.c +++ b/dmake/imacs.c @@ -68,7 +68,7 @@ Create_macro_vars() else #if (_MPW) DirSepStr = ":"; -#elif defined( __EMX__) +#elif defined( __EMX__BACKSLASH) /* Use '\' for OS/2 port. */ DirSepStr = "\\"; #else diff --git a/dmake/make.cmd b/dmake/make.cmd index c0d490ddd969..cb9efc7f606b 100755 --- a/dmake/make.cmd +++ b/dmake/make.cmd @@ -1,17 +1,5 @@ echo off -REM * This script is deprecated for OS/2 libc 06x building! Use the configure -REM * mechanism. Run the following commands your OS/2 shell: -REM * -REM * set CFLAGS=-g -Zomf -O3 -march=pentium -mcpu=pentium4 -REM * set CXXFLAGS=-g -Zomf -O3 -march=pentium -mcpu=pentium4 -REM * set LDFLAGS=-s -Zsym -Zmap -Zhigh-mem -Zomf -Zexe -Zargs-wild -Zargs-resp -REM * set LN_CP_F=cp.exe -REM * set RANLIb=echo -REM * set AR=emxomfar -p128 -REM * sh -c "./configure --enable-spawn" -REM * make.exe - cls rem *** This is the make command file that is used under OS/2 to make the rem *** first version of dmake. It isn't pretty but it does work, assuming @@ -20,6 +8,7 @@ rem if %0%1 == %0 goto error +if %1 == os2-gcc goto mkgcc if %1 == os2-ibm goto mkibm if %1 == os2-ibm3 goto mkibm3 if %1 == winnt-bcc40 goto mkwntb40 @@ -32,14 +21,30 @@ rem label the possible DOS variations for dmake here. :error echo OS/2 INDEX: You must specify one of: echo ------------------ -echo os2-ibm - IBM OS/2 ICC compile. -echo os2-ibm3 - IBM OS/2 ICC3 compile. +echo os2-gcc - gcc&klibc compile (this is the only supported configuration). +echo os2-ibm - IBM OS/2 ICC compile (deprecated). +echo os2-ibm3 - IBM OS/2 ICC3 compile (deprecated). echo winnt-bcc40 - Windows-NT Borland C++ 4.0 Compile echo winnt-bcc45 - Windows-NT Borland C++ 4.5 Compile echo winnt-bcc50 - Windows-NT Borland C++ 5.0 Compile echo winnt-vpp40 - Windows-NT Microsoft VC++ 4.0 Compile goto end +rem This is the script that builds OS/2 dmake using gcc & klibc + +:mkgcc +set CONFIG_SHELL=sh +set CFLAGS=-g -O3 -march=pentium4 +set CXXFLAGS=-g -O3 -march=pentium4 +set LDFLAGS=-s -Zomf -Zhigh-mem -Zargs-wild -Zargs-resp +set LN_CP_F=cp.exe +set RANLIB=echo +set AR=emxomfar -p128 +sh -c "./configure --enable-spawn" +make.exe + +goto end + rem This is the script that bilds OS/2 dmake using IBM ICC Compiler :mkibm os2\ibm\icc\mk.cmd diff --git a/dmake/sysintf.c b/dmake/sysintf.c index 65104114923f..c55d72d331ab 100644 --- a/dmake/sysintf.c +++ b/dmake/sysintf.c @@ -603,7 +603,7 @@ Get_current_dir() if( !getcwd(buf, sizeof(buf)) ) Fatal("Internal Error: Error when calling getcwd()!"); -#ifdef __EMX__ +#ifdef __EMX__BACKSLASH char *slash; slash = buf; while( (slash=strchr(slash,'/')) ) |