diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 2064305d4a..e54a649496 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -8,6 +8,36 @@ 2008-12-31 13:59 UTC+0100 Foo Bar (foo.bar foobar.org) */ +2009-01-29 19:48 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl) + * harbour/bin/postinst.sh + ! added missing export in envvar setting. + + * harbour/config/linux/install.cf + * added error message when install directory is not set. + + * harbour/config/lib.cf + * harbour/config/bin.cf + * harbour/config/dir.cf + + added explicit support for make recursive calls. + Question: why we use $(MK) instead of $(MAKE) so it necessary + to mark recursive make calls manually? + + * harbour/config/dir.cf + * rewritten DIR_RUL to use only GNU make commands instead of + OS scripts. Now config//dir.cf files are not longer used. + Please make build tests on different platforms. If all will + be correct then we remove these files. + + * harbour/source/common/Makefile + * harbour/source/vm/Makefile + * harbour/source/vm/vmmt/Makefile + * moved biggest files to begin of file list for better parallel + compilation utilization. + + * harbour/source/rdd/dbfcdx/dbfcdx1.c + * accept invalid string key expression if codeblock key expression + is given. + 2009-01-29 14:25 UTC+0100 Viktor Szakats (harbour.01 syenar hu) * source/rtl/gtwvt/gtwvt.c ! Fixed to #undef _WIN32_WINNT before setting it. diff --git a/harbour/bin/postinst.sh b/harbour/bin/postinst.sh index c9c207cc89..be4c0e0888 100755 --- a/harbour/bin/postinst.sh +++ b/harbour/bin/postinst.sh @@ -83,7 +83,7 @@ then fi # build hbfm lib with memory statistic (cd ${hb_root}/source/vm - C_USR="${C_USR//-DHB_FM_STATISTICS_OFF/} -DHB_FM_STATISTICS" + export C_USR="${C_USR//-DHB_FM_STATISTICS_OFF/} -DHB_FM_STATISTICS" rm -f fm.o ${MAKE} -r fm.o ${AR} ${AR_OPT} ${HB_LIB_INSTALL}/libhbfm.a fm.o diff --git a/harbour/config/bin.cf b/harbour/config/bin.cf index b4f58dd567..7bc5bb1697 100644 --- a/harbour/config/bin.cf +++ b/harbour/config/bin.cf @@ -30,8 +30,8 @@ ALL_OBJS = $(ALL_C_OBJS) $(ALL_PRG_OBJS) first:: dirbase descend -descend : - @$(MK) -C $(ARCH_DIR) -f $(GRANDP)Makefile 'TOP=$(GRANDP)' $(EXE_NAME) $(MK_USR) +descend:: dirbase + +@$(MK) -C $(ARCH_DIR) -f $(GRANDP)Makefile 'TOP=$(GRANDP)' $(EXE_NAME) $(MK_USR) $(EXE_NAME) : $(ALL_OBJS) $(LD_RULE) diff --git a/harbour/config/dir.cf b/harbour/config/dir.cf index 1de75b114d..cb6cb7ed62 100644 --- a/harbour/config/dir.cf +++ b/harbour/config/dir.cf @@ -6,16 +6,26 @@ ifneq ($(HB_ARCHITECTURE),) ifneq ($(HB_COMPILER),) include $(TOP)$(ROOT)config/global.cf -include $(TOP)$(ROOT)config/$(HB_ARCHITECTURE)/dir.cf +#include $(TOP)$(ROOT)config/$(HB_ARCHITECTURE)/dir.cf + +# NOTE: The empty line directly before 'endef' HAVE TO exist! +# It causes that every commands will be separated by LF +define dir_mk +$(MK) -C $(dir) $@ + +endef + +DIRS_MK = $(foreach d, $(DIRS), $(if $(wildcard $(d)/Makefile),$(d),)) +DIR_RULE = $(foreach dir, $(DIRS_MK), $(dir_mk)) all : first first clean install:: - $(DIR_RULE) + +$(DIR_RULE) ifneq ($(HB_POSTINST),) install:: - $(HB_POSTINST) + +$(HB_POSTINST) endif endif diff --git a/harbour/config/lib.cf b/harbour/config/lib.cf index a7924ca011..985f2f0bf3 100644 --- a/harbour/config/lib.cf +++ b/harbour/config/lib.cf @@ -22,8 +22,8 @@ ALL_OBJS = $(ALL_C_OBJS) $(ALL_PRG_OBJS) first:: dirbase descend -descend : - @$(MK) -C $(ARCH_DIR) -f $(GRANDP)Makefile 'TOP=$(GRANDP)' $(LIB_NAME) $(MK_USR) +descend:: dirbase + +@$(MK) -C $(ARCH_DIR) -f $(GRANDP)Makefile 'TOP=$(GRANDP)' $(LIB_NAME) $(MK_USR) vpath $(LIB_NAME) $(LIB_DIR) $(LIB_NAME) : $(ALL_OBJS) diff --git a/harbour/config/linux/install.cf b/harbour/config/linux/install.cf index 47dbdda067..a34d1e0c9d 100644 --- a/harbour/config/linux/install.cf +++ b/harbour/config/linux/install.cf @@ -3,9 +3,10 @@ # INSTALL_RULE =\ - @if [ ! -d $(INSTALL_DIR) ]; \ + @if [ -z $(INSTALL_DIR) ] || [ ! -d $(INSTALL_DIR) ]; \ then \ - echo "! Can't install, path not found: $(INSTALL_DIR)" 1>&2; \ + echo "! Can't install, path not found: '$(INSTALL_DIR)'" 1>&2; \ + false; \ else \ for i in $(INSTALL_OBJS); \ do \ diff --git a/harbour/source/common/Makefile b/harbour/source/common/Makefile index 8520ce9606..d5304c1025 100644 --- a/harbour/source/common/Makefile +++ b/harbour/source/common/Makefile @@ -5,6 +5,8 @@ ROOT = ../../ C_SOURCES=\ + expropt1.c \ + expropt2.c \ hbfsapi.c \ hbfopen.c \ hbgete.c \ @@ -19,8 +21,6 @@ C_SOURCES=\ hbverdsp.c \ hbarch.c \ reserved.c \ - expropt1.c \ - expropt2.c \ PRG_SOURCES=\ diff --git a/harbour/source/rdd/dbfcdx/dbfcdx1.c b/harbour/source/rdd/dbfcdx/dbfcdx1.c index 36374c52af..d734bc75d5 100644 --- a/harbour/source/rdd/dbfcdx/dbfcdx1.c +++ b/harbour/source/rdd/dbfcdx/dbfcdx1.c @@ -7458,17 +7458,26 @@ static ERRCODE hb_cdxOrderCreate( CDXAREAP pArea, LPDBORDERCREATEINFO pOrderInfo if( SELF_COMPILE( (AREAP) pArea, ( BYTE * ) hb_itemGetCPtr( pOrderInfo->abExpr ) ) == FAILURE ) { - hb_cdxErrorRT( pArea, EG_DATATYPE, EDBF_INVALIDKEY, NULL, 0, 0, NULL ); - return FAILURE; + if( pOrderInfo->itmCobExpr ) + { + pKeyExp = hb_itemNew( pOrderInfo->itmCobExpr ); + } + else + { + hb_cdxErrorRT( pArea, EG_DATATYPE, EDBF_INVALIDKEY, NULL, 0, 0, NULL ); + return FAILURE; + } } - - pKeyExp = pArea->valResult; - pArea->valResult = NULL; - /* If we have a codeblock for the expression, use it */ - if( pOrderInfo->itmCobExpr ) + else { - hb_vmDestroyBlockOrMacro( pKeyExp ); - pKeyExp = hb_itemNew( pOrderInfo->itmCobExpr ); + pKeyExp = pArea->valResult; + pArea->valResult = NULL; + /* If we have a codeblock for the expression, use it */ + if( pOrderInfo->itmCobExpr ) + { + hb_vmDestroyBlockOrMacro( pKeyExp ); + pKeyExp = hb_itemNew( pOrderInfo->itmCobExpr ); + } } /* Get a blank record before testing expression */ diff --git a/harbour/source/vm/Makefile b/harbour/source/vm/Makefile index ae15f08005..0f08002d5f 100644 --- a/harbour/source/vm/Makefile +++ b/harbour/source/vm/Makefile @@ -25,6 +25,7 @@ else endif C_SOURCES=\ + hvm.c \ arrays.c \ arrayshb.c \ asort.c \ @@ -45,7 +46,6 @@ C_SOURCES=\ garbage.c \ hashes.c \ hashfunc.c \ - hvm.c \ initexit.c \ initsymb.c \ itemapi.c \ diff --git a/harbour/source/vm/vmmt/Makefile b/harbour/source/vm/vmmt/Makefile index 2d601edce5..9c5df2b02d 100644 --- a/harbour/source/vm/vmmt/Makefile +++ b/harbour/source/vm/vmmt/Makefile @@ -26,6 +26,7 @@ else endif C_SOURCES=\ + hvm.c \ arrays.c \ arrayshb.c \ asort.c \ @@ -46,7 +47,6 @@ C_SOURCES=\ garbage.c \ hashes.c \ hashfunc.c \ - hvm.c \ initexit.c \ initsymb.c \ itemapi.c \