2010-03-28 11:15 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* INSTALL
* config/rules.mk
+ config/res.mk
* config/bin.mk
* config/wce/global.mk
* config/wce/mingwarm.mk
* config/wce/poccarm.mk
* config/wce/msvcarm.mk
* config/common/watcom.mk
* config/win/xcc.mk
* config/win/mingw.mk
* config/win/pocc.mk
* config/win/bcc.mk
* config/win/watcom.mk
* config/win/cygwin.mk
* config/win/global.mk
* config/win/msvc.mk
* config/os2/watcom.mk
* config/os2/gcc.mk
* config/os2/global.mk
+ Added support to GNU Make system to compile and link resources
on win, wce and os2 platforms.
* bin/postinst.bat
+ Deleted requirements from local comment. These are
documented in INSTALL.
This commit is contained in:
@@ -17,6 +17,34 @@
|
||||
past entries belonging to author(s): Viktor Szakats.
|
||||
*/
|
||||
|
||||
2010-03-28 11:15 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* INSTALL
|
||||
* config/rules.mk
|
||||
+ config/res.mk
|
||||
* config/bin.mk
|
||||
* config/wce/global.mk
|
||||
* config/wce/mingwarm.mk
|
||||
* config/wce/poccarm.mk
|
||||
* config/wce/msvcarm.mk
|
||||
* config/common/watcom.mk
|
||||
* config/win/xcc.mk
|
||||
* config/win/mingw.mk
|
||||
* config/win/pocc.mk
|
||||
* config/win/bcc.mk
|
||||
* config/win/watcom.mk
|
||||
* config/win/cygwin.mk
|
||||
* config/win/global.mk
|
||||
* config/win/msvc.mk
|
||||
* config/os2/watcom.mk
|
||||
* config/os2/gcc.mk
|
||||
* config/os2/global.mk
|
||||
+ Added support to GNU Make system to compile and link resources
|
||||
on win, wce and os2 platforms.
|
||||
|
||||
* bin/postinst.bat
|
||||
+ Deleted requirements from local comment. These are
|
||||
documented in INSTALL.
|
||||
|
||||
2010-03-27 10:46 UTC-0800 Pritpal Bedi (pritpal@vouchcac.com)
|
||||
* contrib/hbxbp/xbpgra.prg
|
||||
! GraInitMaterix(...) => GraInitMatrix(...)
|
||||
|
||||
@@ -563,6 +563,7 @@ HARBOUR
|
||||
|
||||
- HB_USER_PRGFLAGS User Harbour compiler options
|
||||
- HB_USER_CFLAGS User C compiler options
|
||||
- HB_USER_RESFLAGS User resource compiler options (on win, wce, os2)
|
||||
- HB_USER_LDFLAGS User linker options for executables
|
||||
- HB_USER_AFLAGS User linker options for libraries
|
||||
- HB_USER_DFLAGS User linker options for dynamic libraries
|
||||
|
||||
@@ -10,18 +10,6 @@ rem See COPYING for licensing terms.
|
||||
rem
|
||||
rem Script run after Harbour make install to finish install process
|
||||
rem (for Windows/DOS)
|
||||
rem
|
||||
rem Contains: install package creator script, which requires:
|
||||
rem
|
||||
rem - Info-ZIP zip.exe in PATH
|
||||
rem or HB_DIR_ZIP envvar set to its dir with an ending backslash.
|
||||
rem https://sourceforge.net/project/showfiles.php?group_id=118012
|
||||
rem - NullSoft Installer installed (NSIS)
|
||||
rem https://sourceforge.net/project/showfiles.php?group_id=22049&package_id=15374
|
||||
rem (only for Windows builds)
|
||||
rem - makensis.exe (part of NSIS) in PATH
|
||||
rem or HB_DIR_NSIS envvar set to its dir with an ending backslash.
|
||||
rem (only for Windows builds)
|
||||
rem ---------------------------------------------------------------
|
||||
|
||||
if "%HB_BIN_INSTALL%" == "" echo ! HB_BIN_INSTALL needs to be set.
|
||||
|
||||
@@ -121,6 +121,7 @@ LIBS := $(HB_USER_LIBS) $(LIBS)
|
||||
include $(TOP)$(ROOT)config/$(HB_PLATFORM)/$(HB_COMPILER).mk
|
||||
include $(TOP)$(ROOT)config/c.mk
|
||||
include $(TOP)$(ROOT)config/prg.mk
|
||||
include $(TOP)$(ROOT)config/res.mk
|
||||
|
||||
BIN_NAME :=
|
||||
|
||||
@@ -139,6 +140,9 @@ endif
|
||||
BIN_FILE := $(BIN_DIR)/$(BIN_NAME)
|
||||
|
||||
ALL_OBJS := $(ALL_C_OBJS) $(ALL_PRG_OBJS)
|
||||
ifneq ($(RC),)
|
||||
ALL_OBJS += $(ALL_RC_OBJS)
|
||||
endif
|
||||
|
||||
first:: dirbase descend
|
||||
|
||||
|
||||
@@ -24,9 +24,15 @@ AR := wlib
|
||||
ARFLAGS += -q -p=72 -c -n
|
||||
|
||||
comma := ,
|
||||
LDFILES_COMMA = $(subst $(subst x,x, ),$(comma) ,$(^F))
|
||||
ifneq ($(RES_EXT),)
|
||||
LDFILES_COMMA = $(subst $(subst x,x, ),$(comma) ,$(filter-out %$(RES_EXT),$(^F)))
|
||||
LDRES_LIST = $(foreach file,$(filter %$(RES_EXT),$(^F)),OPT res=$(file))
|
||||
else
|
||||
LDFILES_COMMA = $(subst $(subst x,x, ),$(comma) ,$(^F))
|
||||
LDRES_LIST :=
|
||||
endif
|
||||
LDLIBS_COMMA := $(subst $(subst x,x, ),$(comma) ,$(strip $(LDLIBS)))
|
||||
LD_RULE = $(LD) $(LDFLAGS) $(HB_LDFLAGS) $(HB_USER_LDFLAGS) NAME $(BIN_DIR)/$@ FILE $(LDFILES_COMMA) $(if $(LDLIBS_COMMA), LIB $(LDLIBS_COMMA),)
|
||||
LD_RULE = $(LD) $(LDFLAGS) $(HB_LDFLAGS) $(HB_USER_LDFLAGS) NAME $(BIN_DIR)/$@ FILE $(LDFILES_COMMA) $(LDRES_LIST) $(if $(LDLIBS_COMMA), LIB $(LDLIBS_COMMA),)
|
||||
AR_RULE = $(AR) $(ARFLAGS) $(HB_AFLAGS) $(HB_USER_AFLAGS) $(LIB_DIR)/$@ $(foreach file,$(^F),-+$(file))
|
||||
|
||||
ifeq ($(HB_SHELL),dos)
|
||||
|
||||
@@ -39,6 +39,14 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -g
|
||||
endif
|
||||
|
||||
RC := windres
|
||||
RC_OUT := -o$(subst x,x, )
|
||||
ifeq ($(HB_COMPILER),gccomf)
|
||||
RCFLAGS := -O omf
|
||||
else
|
||||
RCFLAGS := -O coff
|
||||
endif
|
||||
|
||||
ifneq ($(filter $(HB_BUILD_STRIP),all lib),)
|
||||
ifeq ($(HB_COMPILER),gccomf)
|
||||
ARSTRIP = & ${HB_CCPATH}${HB_CCPREFIX}stripomf -S $(LIB_DIR)/$@
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
all : first
|
||||
|
||||
RES_EXT := .res
|
||||
BIN_EXT := .exe
|
||||
DYN_EXT := .dll
|
||||
|
||||
|
||||
@@ -57,6 +57,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -d2
|
||||
endif
|
||||
|
||||
RC := wrc
|
||||
RC_OUT := -fo=
|
||||
RCFLAGS := -q -r -zm -bt=os2
|
||||
|
||||
LD := wlink
|
||||
ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
LDFLAGS += DEBUG ALL
|
||||
|
||||
5
harbour/config/res.mk
Normal file
5
harbour/config/res.mk
Normal file
@@ -0,0 +1,5 @@
|
||||
#
|
||||
# $Id$
|
||||
#
|
||||
|
||||
ALL_RC_OBJS := $(RC_SOURCES:.rc=$(RES_EXT))
|
||||
@@ -62,6 +62,13 @@ ifeq ($(CPP_RULE),)
|
||||
CPP_RULE = $(CXX) $(CC_FLAGS) $(HB_USER_CFLAGS) $(CC_OUT)$(<F:.cpp=$(OBJ_EXT)) $(CC_IN) $<
|
||||
endif
|
||||
|
||||
# The rule to compile resources.
|
||||
ifneq ($(RC),)
|
||||
ifeq ($(RC_RULE),)
|
||||
RC_RULE = $(RC) $(RCFLAGS) $(HB_RCFLAGS) $(HB_USER_RESFLAGS) $(RC_OUT)$(<F:.rc=$(RES_EXT)) $<
|
||||
endif
|
||||
endif
|
||||
|
||||
# The rule to link an executable.
|
||||
ifeq ($(LD_RULE),)
|
||||
LD_RULE = $(LD) $(LDFLAGS) $(HB_LDFLAGS) $(HB_USER_LDFLAGS) $(LD_OUT)$(subst /,$(DIRSEP),$(BIN_DIR)/$@) $(^F) $(LDLIBS) $(LDSTRIP)
|
||||
@@ -85,8 +92,15 @@ endif
|
||||
%$(OBJ_EXT) : %.cpp
|
||||
$(CPP_RULE)
|
||||
|
||||
# Rules for resource files
|
||||
%$(RES_EXT) : $(GRANDP)%.rc
|
||||
$(RC_RULE)
|
||||
|
||||
%$(RES_EXT) : %.rc
|
||||
$(RC_RULE)
|
||||
|
||||
# Rule to generate an executable file from an object file.
|
||||
%$(BIN_EXT) : %$(OBJ_EXT)
|
||||
%$(BIN_EXT) : %$(OBJ_EXT) %$(RES_EXT)
|
||||
$(LD_RULE)
|
||||
|
||||
# Rule to generate a C file from a PRG file.
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
all : first
|
||||
|
||||
RES_EXT := .res
|
||||
BIN_EXT := .exe
|
||||
DYN_EXT := .dll
|
||||
|
||||
|
||||
@@ -34,6 +34,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -g
|
||||
endif
|
||||
|
||||
RC := windres
|
||||
RC_OUT := -o$(subst x,x, )
|
||||
RCFLAGS := -O coff
|
||||
|
||||
ifneq ($(filter $(HB_BUILD_STRIP),all lib),)
|
||||
ARSTRIP = && ${HB_CCPATH}${HB_CCPREFIX}strip -S $(LIB_DIR)/$@
|
||||
endif
|
||||
|
||||
@@ -72,6 +72,13 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
DFLAGS += -debug
|
||||
endif
|
||||
|
||||
RC := rc.exe
|
||||
RC_OUT := -fo$(subst x,x, )
|
||||
RCFLAGS :=
|
||||
ifeq ($(filter $(HB_COMPILER_VER),600 700 710 800 900),)
|
||||
RCFLAGS += -nologo
|
||||
endif
|
||||
|
||||
LD := link.exe
|
||||
LD_OUT := -out:
|
||||
|
||||
|
||||
@@ -38,6 +38,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -Zi
|
||||
endif
|
||||
|
||||
RC := porc.exe
|
||||
RC_OUT := -fo$(subst x,x, )
|
||||
RCFLAGS :=
|
||||
|
||||
LD := polink.exe
|
||||
LD_OUT := -out:
|
||||
|
||||
|
||||
@@ -46,10 +46,14 @@ ifneq ($(HB_COMP_PATH_PUB),)
|
||||
DFLAGS += $(subst /,\,-L"$(HB_COMP_PATH_PUB)../Lib" -L"$(HB_COMP_PATH_PUB)../Lib/PSDK")
|
||||
endif
|
||||
|
||||
RC := brcc32.exe
|
||||
RC_OUT := -fo
|
||||
RCFLAGS :=
|
||||
|
||||
LD := ilink32.exe
|
||||
LIBPATHS := $(subst /,\,-L"$(LIB_DIR)")
|
||||
LDFLAGS += $(LIBPATHS) -Gn -Tpe
|
||||
LD_RULE = $(LD) $(LDFLAGS) $(HB_LDFLAGS) $(HB_USER_LDFLAGS) c0x32.obj $(^F), "$(subst /,\,$(BIN_DIR)/$@)", nul, $(LDLIBS) cw32mt import32 $(LDSTRIP)
|
||||
LD_RULE = $(LD) $(LDFLAGS) $(HB_LDFLAGS) $(HB_USER_LDFLAGS) c0x32.obj $(filter-out %$(RES_EXT),$(^F)), "$(subst /,\,$(BIN_DIR)/$@)", nul, $(LDLIBS) cw32mt import32,, $(filter %$(RES_EXT),$(^F)) $(LDSTRIP)
|
||||
|
||||
LDLIBS := $(strip $(HB_USER_LIBS) $(LIBS) $(SYSLIBS))
|
||||
|
||||
|
||||
@@ -31,6 +31,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -g
|
||||
endif
|
||||
|
||||
RC := windres
|
||||
RC_OUT := -o$(subst x,x, )
|
||||
RCFLAGS := -O coff
|
||||
|
||||
ifneq ($(filter $(HB_BUILD_STRIP),all lib),)
|
||||
ARSTRIP = && ${HB_CCPATH}${HB_CCPREFIX}strip -S $(LIB_DIR)/$@
|
||||
endif
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
|
||||
all : first
|
||||
|
||||
RES_EXT := .res
|
||||
BIN_EXT := .exe
|
||||
DYN_EXT := .dll
|
||||
|
||||
|
||||
@@ -50,6 +50,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -g
|
||||
endif
|
||||
|
||||
RC := windres
|
||||
RC_OUT := -o$(subst x,x, )
|
||||
RCFLAGS := -O coff
|
||||
|
||||
ifneq ($(filter $(HB_BUILD_STRIP),all lib),)
|
||||
ARSTRIP = && ${HB_CCPATH}${HB_CCPREFIX}strip -S $(LIB_DIR)/$@
|
||||
endif
|
||||
|
||||
@@ -59,6 +59,13 @@ ifneq ($(filter $(HB_COMPILER_VER),600 700 710),)
|
||||
endif
|
||||
endif
|
||||
|
||||
RC := rc.exe
|
||||
RC_OUT := -fo$(subst x,x, )
|
||||
RCFLAGS :=
|
||||
ifeq ($(filter $(HB_COMPILER_VER),600 700 710 800 900),)
|
||||
RCFLAGS += -nologo
|
||||
endif
|
||||
|
||||
# # NOTE: -GA flag should be disabled when building MT _.dlls_,
|
||||
# # as it creates bad code according to MS docs [vszakats].
|
||||
# ifneq ($(filter $(HB_COMPILER_VER),600),)
|
||||
|
||||
@@ -33,6 +33,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -Zi
|
||||
endif
|
||||
|
||||
RC := porc.exe
|
||||
RC_OUT := -fo$(subst x,x, )
|
||||
RCFLAGS :=
|
||||
|
||||
LD := polink.exe
|
||||
LD_OUT := -out:
|
||||
|
||||
|
||||
@@ -51,6 +51,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -d2
|
||||
endif
|
||||
|
||||
RC := wrc
|
||||
RC_OUT := -fo=
|
||||
RCFLAGS := -q -r -zm -bt=nt
|
||||
|
||||
LD := wlink
|
||||
ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
LDFLAGS += DEBUG ALL
|
||||
|
||||
@@ -41,6 +41,10 @@ ifeq ($(HB_BUILD_DEBUG),yes)
|
||||
CFLAGS += -Zi
|
||||
endif
|
||||
|
||||
RC := xRC.exe
|
||||
RC_OUT := -fo$(subst x,x, )
|
||||
RCFLAGS :=
|
||||
|
||||
LD := xLink.exe
|
||||
LD_OUT := -out:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user