Files
harbour-core/harbour/config/bin.mk
Przemyslaw Czerpak dd756dc5cf 2009-09-01 21:00 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/config/lib.mk
  * harbour/config/bin.mk
  * harbour/config/header.mk
  * harbour/config/dyn.mk
  * harbour/config/doc.mk
  * harbour/config/instsh.mk
    ! rewritten install rules so now they work without any problem when
      more then one target .mk file is included, i.e. lib.mk and header.mk

  * harbour/source/pp/Makefile
  * harbour/source/dynlib/mt/Makefile
  * harbour/source/dynlib/Makefile
  * harbour/contrib/hbmysql/Makefile
  * harbour/contrib/hbct/Makefile
  * harbour/contrib/xhb/Makefile
  * harbour/contrib/hbodbc/Makefile
  * harbour/contrib/hbtpathy/Makefile
  * harbour/contrib/hbsqlit3/Makefile
  * harbour/contrib/hbmzip/Makefile
  * harbour/contrib/hbblat/Makefile
  * harbour/contrib/hbqt/Makefile
  * harbour/contrib/hbxbp/Makefile
  * harbour/contrib/xpp/Makefile
  * harbour/contrib/hbnf/Makefile
  * harbour/contrib/hbcurl/Makefile
  * harbour/contrib/gtqtc/Makefile
  * harbour/contrib/rddsql/sddmy/Makefile
  * harbour/contrib/rddsql/sddpg/Makefile
  * harbour/contrib/rddsql/sddfb/Makefile
  * harbour/contrib/rddsql/sddodbc/Makefile
  * harbour/contrib/hbhpdf/Makefile
  * harbour/contrib/rddado/Makefile
  * harbour/contrib/gtwvg/Makefile
  * harbour/contrib/hbpgsql/Makefile
  * harbour/contrib/hbclipsm/Makefile
  * harbour/contrib/rddads/Makefile
  * harbour/contrib/hbfimage/Makefile
  * harbour/contrib/hbgd/Makefile
  * harbour/contrib/hbtip/Makefile
  * harbour/contrib/hbwin/Makefile
  * harbour/contrib/hbvpdf/Makefile
  * harbour/contrib/hbbtree/Makefile
  * harbour/contrib/hbssl/Makefile
  * harbour/external/libhpdf/Makefile
    * removed not longer necessary workaround for overwritten by different
      targets INSTALL_RULE
      Possible TODO: clean up some other rules in config .mk files to remove
      hacks from pp and dynlib Makefile(s).

   Above modifications should fully resolve the problems with repeated
   install actions and also build problems with some more restrictive
   POSIX SHELLs.
2009-09-01 19:05:19 +00:00

111 lines
2.0 KiB
Makefile

#
# $Id$
#
include $(TOP)$(ROOT)config/global.mk
ifneq ($(HB_PLATFORM),)
ifneq ($(HB_COMPILER),)
# Assemble template lib list to help create a few common variations
# (have to use '=' operator here)
HB_LIBS_TPL = \
hbextern \
hbdebug \
$(_HB_VM) \
hbrtl \
hblang \
hbcpage \
$(HB_GT_LIBS) \
$(_HB_RDD) \
hbrtl \
$(_HB_VM) \
hbmacro \
hbcplr \
hbpp \
hbcommon
ifeq ($(filter -DHB_PCRE_REGEX, $(HB_USER_CFLAGS)),)
ifeq ($(filter -DHB_POSIX_REGEX, $(HB_USER_CFLAGS)),)
HB_LIBS_TPL += hbpcre
endif
endif
ifeq ($(filter -DHB_EXT_ZLIB, $(HB_USER_CFLAGS)),)
HB_LIBS_TPL += hbzlib
endif
# Create a few common core lib lists
_HB_RDD := hbrdd $(HB_RDD_LIBS)
_HB_VM := hbvm
HB_LIBS_ST_RDD := $(HB_LIBS_TPL)
_HB_VM := hbvmmt
HB_LIBS_MT_RDD := $(HB_LIBS_TPL)
_HB_RDD := hbnulrdd
_HB_VM := hbvm
HB_LIBS_ST_NORDD := $(HB_LIBS_TPL)
_HB_VM := hbvmmt
HB_LIBS_MT_NORDD := $(HB_LIBS_TPL)
# Cleanup temp vars
HB_LIBS_TPL :=
_HB_RDD :=
_HB_VM :=
HB_LINKING_RTL :=
HB_LINKING_VMMT :=
ifneq ($(filter hbrtl, $(LIBS)),)
HB_LINKING_RTL := yes
ifneq ($(filter hbvmmt, $(LIBS)),)
HB_LINKING_VMMT := yes
endif
endif
-include $(TOP)$(ROOT)config/$(HB_PLATFORM)/libs.mk
include $(TOP)$(ROOT)config/$(HB_PLATFORM)/$(HB_COMPILER).mk
include $(TOP)$(ROOT)config/c.mk
include $(TOP)$(ROOT)config/prg.mk
BIN_NAME :=
ifneq ($(C_MAIN),)
ifeq ($(BIN_NAME),)
BIN_NAME := $(C_MAIN:.c=$(BIN_EXT))
endif
endif
ifneq ($(PRG_MAIN),)
ifeq ($(BIN_NAME),)
BIN_NAME := $(PRG_MAIN:.prg=$(BIN_EXT))
endif
endif
BIN_FILE := $(BIN_DIR)/$(BIN_NAME)
ALL_OBJS := $(ALL_C_OBJS) $(ALL_PRG_OBJS)
first:: dirbase descend
descend:: dirbase
+@$(MK) $(MKFLAGS) -C $(OBJ_DIR) -f $(GRANDP)Makefile TOP=$(GRANDP) $(BIN_NAME)
vpath $(BIN_NAME) $(BIN_DIR)
$(BIN_NAME) : $(ALL_OBJS)
$(LD_RULE)
INSTALL_FILES := $(BIN_FILE)
INSTALL_DIR := $(HB_BIN_INSTALL)
include $(TOP)$(ROOT)config/instsh.mk
INSTALL_RULE_BIN := $(INSTALL_RULE)
ifneq ($(INSTALL_RULE_BIN),)
install:: first
$(INSTALL_RULE_BIN)
endif
endif
endif