Files
harbour-core/harbour/config/rules.cf
Viktor Szakats f0459c8187 2009-08-10 17:23 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* contrib/hbtpathy/telepath.prg
    ! Fixed forming default COM port names on Windows NT
      systems. (I didn't test Win9x, but I assume they work
      like DOS regarding this aspect).

  * contrib/hbxbp/Makefile
  * contrib/gtwvg/Makefile
    ! Using HB_INC_DEPEND instead of modifying HB_USER_PRGFLAGS
      and HB_USER_CFLAGS. Old solution wasn't good because the
      new include dirs were added after central ones, so central
      ones effectively masked them and wrong headers could be
      picked through the build.

  * config/rules.cf
    + Added HB_INC_DEPEND variable to store dirs which should
      be included before central include dir.

  * config/global.cf
    * Small change in predefined HB_BUILD_NAMEs. Unicode 'u'
      marker moved to end, C++ marked changed to 'p' (from 'x').

  * contrib/rddado/rddado.hbc
  * contrib/gtwvg/gtwvg.hbc
    * Slash sync with other .hbc files. (forward slash is used)

  * config/dos/watcom.cf
    % Minor opt in operator.
2009-08-10 15:27:05 +00:00

76 lines
1.8 KiB
CFEngine3

#
# $Id$
#
# How to run yacc.
YACC := bison
YACC_FLAGS := -d $(YACC_FLAGS)
# How to run lex.
LEX := flex
LEX_FLAGS := -i -8 $(LEX_FLAGS)
ifeq ($(HB_BUILD_DEBUG),yes)
HB_CDBG := -DHB_TR_LEVEL_DEBUG
else
HB_PDBG := -l
endif
ifeq ($(HB_BUILD_UNICODE),yes)
HB_CUNICODE := -DUNICODE
endif
# How to run Harbour
HB := $(HB_HOST_BIN_DIR)/harbour$(HB_HOST_BIN_EXT)
ifeq ($(HB_GCMODE),)
HB_GCMODE := 0
endif
HB_FLAGS := -i$(HB_INC_COMPILE) -q0 -w3 -es2 -kmo $(HB_PDBG)
HB_RULE = $(HB) $? -n1 $(HB_INC_DEPEND) $(HB_FLAGS) -gc$(HB_GCMODE) $(HB_FLAGSEXTRA) $(HB_USER_PRGFLAGS)
# Use default rules if architecture/compiler specific rule is not defined
# The rule to compile a C source file.
ifeq ($(CC_RULE),)
CC_RULE = $(CC) $(HB_INC_DEPEND) $(CPPFLAGS) $(CFLAGS) $(HB_CDBG) $(HB_USER_CFLAGS) $(HB_CDYNLIB) $(HB_CUNICODE) $(CC_IN) $< $(CC_OUT)$(<F:.c=$(OBJ_EXT))
endif
# The rule to compile a C++ source file.
ifeq ($(CPP_RULE),)
CPP_RULE = $(CC) $(HB_INC_DEPEND) $(CPPFLAGS) $(CFLAGS) $(HB_CDBG) $(HB_USER_CFLAGS) $(HB_CDYNLIB) $(HB_CUNICODE) $(CC_IN) $< $(CC_OUT)$(<F:.cpp=$(OBJ_EXT))
endif
# The rule to link an executable.
ifeq ($(LD_RULE),)
LD_RULE = $(LD) $(CFLAGS) $(LD_OUT)$(subst /,$(DIRSEP),$(BIN_DIR)/$@) $(^F) $(LDFLAGS) $(HB_USER_LDFLAGS) $(LINKLIBS)
endif
# Eliminate these rules.
%.c : %.y
%.c : %.l
# Rule to generate an object file from a C source file in the parent.
%$(OBJ_EXT) : $(GRANDP)%.c
$(CC_RULE)
# Rule to generate an object file from a C source file.
%$(OBJ_EXT) : %.c
$(CC_RULE)
# Rules for CPP files
%$(OBJ_EXT) : $(GRANDP)%.cpp
$(CPP_RULE)
%$(OBJ_EXT) : %.cpp
$(CPP_RULE)
# Rule to generate an executable file from an object file.
%$(BIN_EXT) : %$(OBJ_EXT)
$(LD_RULE)
# Rule to generate a C file from a PRG file.
%.c : $(GRANDP)%.prg
$(HB_RULE)