* utils/hbmk2/hbmk2.prg
* config/global.mk
! Fixed to -undef:__PLATFORM__UNIX even for Windows host platforms.
This is required because Cygwin builds have this envvar set.
I'm not sure that setting __PLATFORM__UNIX for Cygwin is right
behavior though.
* config/dos/watcom.mk
* config/win/watcom.mk
* config/linux/watcom.mk
* config/os2/watcom.mk
+ config/common/watcom.mk
% Moved common watcom compiler specific make logic to one file.
I've choosen OS/2 rules in this global makefile, as they will
work on all platforms, albeit in the known slighly hacky way.
It's easy to reintroduce shell specific rules for more advanced
shells. There was one common rule set for nt/dos shells, plus
a very clean one for sh. I may do this in a next commit.
After this change it's possible to create all possible watcom
cross-builds. Pls shout if I missed something or the concept
seems to have some potential flaws.
; QUESTION: Does 'wlib' support '-p=64' option on Linux watcom builds?
; NOTE: Still most of the not yet merged logic could be merged,
since there is only a few minor difference between them.
; TODO: Add shell optimized watcom rules for nt/dos/sh shells.
; TODO: Try to do a similar stunt for gcc.mk files.
* source/pp/ppcore.c
* #ifdef -> #if defined()
72 lines
1.4 KiB
Makefile
72 lines
1.4 KiB
Makefile
#
|
|
# $Id$
|
|
#
|
|
|
|
# GNU MAKE file for Open Watcom C/C++ compiler
|
|
|
|
# ---------------------------------------------------------------
|
|
# See option docs here:
|
|
# http://www.users.pjwstk.edu.pl/~jms/qnx/help/watcom/compiler-tools/cpopts.html
|
|
# http://www.users.pjwstk.edu.pl/~jms/qnx/help/watcom/compiler-tools/wlink.html
|
|
# http://www.users.pjwstk.edu.pl/~jms/qnx/help/watcom/compiler-tools/wlib.html
|
|
# ---------------------------------------------------------------
|
|
|
|
OBJ_EXT := .o
|
|
LIB_PREF :=
|
|
LIB_EXT := .lib
|
|
|
|
ifeq ($(HB_BUILD_MODE),c)
|
|
CC := wcc386
|
|
endif
|
|
ifeq ($(HB_BUILD_MODE),cpp)
|
|
CC := wpp386
|
|
endif
|
|
# Build in C++ mode by default
|
|
ifeq ($(HB_BUILD_MODE),)
|
|
CC := wpp386
|
|
endif
|
|
CC_IN :=
|
|
CC_OUT := -fo=
|
|
|
|
CPPFLAGS := -zq -bt=linux
|
|
CFLAGS :=
|
|
LDFLAGS :=
|
|
|
|
ifneq ($(HB_BUILD_WARN),no)
|
|
CPPFLAGS += -w3
|
|
endif
|
|
|
|
ifneq ($(HB_BUILD_OPTIM),no)
|
|
# architecture flags
|
|
CPPFLAGS += -6r -fp6
|
|
|
|
# optimization flags
|
|
# don't enable -ol optimization in OpenWatcom 1.1 - gives buggy code
|
|
# -oxaht
|
|
CPPFLAGS += -onaehtr -s -ei -zp4 -zt0
|
|
#CPPFLAGS += -obl+m
|
|
ifeq ($(CC),wpp386)
|
|
CPPFLAGS += -oi+
|
|
else
|
|
CPPFLAGS += -oi
|
|
endif
|
|
else
|
|
CPPFLAGS += -3r
|
|
endif
|
|
|
|
CPPFLAGS += -i. -i$(HB_INC_COMPILE)
|
|
|
|
ifeq ($(HB_BUILD_DEBUG),yes)
|
|
CPPFLAGS += -d2
|
|
endif
|
|
|
|
LD := wlink
|
|
ifeq ($(HB_BUILD_DEBUG),yes)
|
|
LDFLAGS += DEBUG ALL
|
|
endif
|
|
LDFLAGS += SYS linux
|
|
|
|
include $(TOP)$(ROOT)config/common/watcom.mk
|
|
|
|
include $(TOP)$(ROOT)config/rules.mk
|