From 59967d646b4d25f26b2311fbaa67df663d270bd1 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Tue, 9 Jun 2009 08:53:24 +0000 Subject: [PATCH] 2009-06-09 10:51 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) * INSTALL * Minor simplification. * make_gnu.bat * Minor cleanup. - Deleted 'don't modify, this is a template' text. * utils/hbmk2/hbmk2.prg + Targets will now get an alternate workdir by default on win/wce platforms when using -hbdyn. ; TOFIX: ? HB_DYNLIB usage should be cleaned and synced with GNU Make system. Current HB_DYNLIB usage: GNU Make system: ( win or wce ) and non-gcc hbmk2: ( win or wce ) * contrib/Makefile - contrib/hbmsql + examples/hbmsql * Moved hbmsql to examples. - examples/hbmsql/Makefile + examples/hbmsql/hbmsql.hbp + Changed GNU Make file to hbmk2 make file. * examples/hbmake/hbmake.hbp * Minor to comment. --- harbour/ChangeLog | 29 +++++++++++++++++++ harbour/INSTALL | 5 ++-- harbour/contrib/Makefile | 1 - harbour/contrib/hbmsql/Makefile | 23 --------------- harbour/examples/hbmake/hbmake.hbp | 4 +-- harbour/examples/hbmsql/hbmsql.hbp | 10 +++++++ harbour/{contrib => examples}/hbmsql/msql.c | 0 harbour/{contrib => examples}/hbmsql/msql.ch | 0 harbour/{contrib => examples}/hbmsql/msql.h | 0 .../{contrib => examples}/hbmsql/readme.txt | 0 .../hbmsql/tests/dbf2msql.prg | 0 .../hbmsql/tests/hbmsql.hbc | 0 .../hbmsql/tests/test.prg | 0 .../{contrib => examples}/hbmsql/tmsql.prg | 0 harbour/make_gnu.bat | 28 +++++------------- harbour/utils/hbmk2/hbmk2.prg | 9 +++++- 16 files changed, 59 insertions(+), 50 deletions(-) delete mode 100644 harbour/contrib/hbmsql/Makefile create mode 100644 harbour/examples/hbmsql/hbmsql.hbp rename harbour/{contrib => examples}/hbmsql/msql.c (100%) rename harbour/{contrib => examples}/hbmsql/msql.ch (100%) rename harbour/{contrib => examples}/hbmsql/msql.h (100%) rename harbour/{contrib => examples}/hbmsql/readme.txt (100%) rename harbour/{contrib => examples}/hbmsql/tests/dbf2msql.prg (100%) rename harbour/{contrib => examples}/hbmsql/tests/hbmsql.hbc (100%) rename harbour/{contrib => examples}/hbmsql/tests/test.prg (100%) rename harbour/{contrib => examples}/hbmsql/tmsql.prg (100%) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 159fb4d0fd..45d93412f5 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -17,6 +17,35 @@ past entries belonging to author(s): Viktor Szakats. */ +2009-06-09 10:51 UTC+0200 Viktor Szakats (harbour.01 syenar.hu) + * INSTALL + * Minor simplification. + + * make_gnu.bat + * Minor cleanup. + - Deleted 'don't modify, this is a template' text. + + * utils/hbmk2/hbmk2.prg + + Targets will now get an alternate workdir by default + on win/wce platforms when using -hbdyn. + ; TOFIX: ? HB_DYNLIB usage should be cleaned and synced with + GNU Make system. + Current HB_DYNLIB usage: + GNU Make system: ( win or wce ) and non-gcc + hbmk2: ( win or wce ) + + * contrib/Makefile + - contrib/hbmsql + + examples/hbmsql + * Moved hbmsql to examples. + + - examples/hbmsql/Makefile + + examples/hbmsql/hbmsql.hbp + + Changed GNU Make file to hbmk2 make file. + + * examples/hbmake/hbmake.hbp + * Minor to comment. + 2009-06-09 10:54 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl) * harbour/source/rtl/do.c ! fixed mistake in previous commit diff --git a/harbour/INSTALL b/harbour/INSTALL index a8a14c0ac8..634d95ad92 100644 --- a/harbour/INSTALL +++ b/harbour/INSTALL @@ -296,7 +296,6 @@ EXAMPLES Don't use spaces in dirs. - '%1 %2' can be empty, 'clean', 'install' or 'clean install' depending on what you want to do. - - Windows implib creation setup may change in the future. - Cross build setup (HB_BIN_COMPILE, HB_COMP_PATH, HB_PPGEN_PATH) is tentative. @@ -547,8 +546,8 @@ TROUBLESHOOTING to get the source. - Keep you PATH clean from old, mixed compiler tools or other Harbour versions when building Harbour. The surest way to achieve this is to - leave only GNU Make directory and compiler directory in PATH (order - significant): set PATH=C:\;C:\ + leave only compiler directory in PATH: + set PATH=C:\ - Remove all old, unnecessary environment variables from your environment. Use only those documented in this file. - Try to do no or only small modifications at once to command examples diff --git a/harbour/contrib/Makefile b/harbour/contrib/Makefile index 971cff1536..5b7efc8b22 100644 --- a/harbour/contrib/Makefile +++ b/harbour/contrib/Makefile @@ -38,7 +38,6 @@ DIRS +=\ hbfimage \ hbgd \ hbhpdf \ - hbmsql \ hbmysql \ hbpgsql \ hbqt \ diff --git a/harbour/contrib/hbmsql/Makefile b/harbour/contrib/hbmsql/Makefile deleted file mode 100644 index 5b228757ac..0000000000 --- a/harbour/contrib/hbmsql/Makefile +++ /dev/null @@ -1,23 +0,0 @@ -# -# $Id$ -# - -ROOT = ../../ - -LIBNAME=hbmsql - -C_SOURCES=\ - msql.c \ - -PRG_SOURCES=\ - tmsql.prg \ - -PRG_HEADERS=\ - msql.ch \ - -include $(TOP)$(ROOT)config/header.cf -INSTALL_RULE_HEADERS := $(INSTALL_RULE) -include $(TOP)$(ROOT)config/lib.cf - -install:: - $(INSTALL_RULE_HEADERS) diff --git a/harbour/examples/hbmake/hbmake.hbp b/harbour/examples/hbmake/hbmake.hbp index f8a0888121..b19f014d82 100644 --- a/harbour/examples/hbmake/hbmake.hbp +++ b/harbour/examples/hbmake/hbmake.hbp @@ -2,10 +2,10 @@ # $Id$ # -# To build 'hbmake', type: 'hbmk2 hbmake.hbp' +# To build hbmake, type: 'hbmk2 hbmake.hbp' hbmake.prg hbmakec.c -# Copy to Harbour binary directory for convenience: +# Copy to Harbour binary directory for convenience -instpath=${HB_BIN}/ diff --git a/harbour/examples/hbmsql/hbmsql.hbp b/harbour/examples/hbmsql/hbmsql.hbp new file mode 100644 index 0000000000..b0e87ece15 --- /dev/null +++ b/harbour/examples/hbmsql/hbmsql.hbp @@ -0,0 +1,10 @@ +# +# $Id$ +# + +-hblib + +-ohbmsql + +msql.c +tmsql.prg diff --git a/harbour/contrib/hbmsql/msql.c b/harbour/examples/hbmsql/msql.c similarity index 100% rename from harbour/contrib/hbmsql/msql.c rename to harbour/examples/hbmsql/msql.c diff --git a/harbour/contrib/hbmsql/msql.ch b/harbour/examples/hbmsql/msql.ch similarity index 100% rename from harbour/contrib/hbmsql/msql.ch rename to harbour/examples/hbmsql/msql.ch diff --git a/harbour/contrib/hbmsql/msql.h b/harbour/examples/hbmsql/msql.h similarity index 100% rename from harbour/contrib/hbmsql/msql.h rename to harbour/examples/hbmsql/msql.h diff --git a/harbour/contrib/hbmsql/readme.txt b/harbour/examples/hbmsql/readme.txt similarity index 100% rename from harbour/contrib/hbmsql/readme.txt rename to harbour/examples/hbmsql/readme.txt diff --git a/harbour/contrib/hbmsql/tests/dbf2msql.prg b/harbour/examples/hbmsql/tests/dbf2msql.prg similarity index 100% rename from harbour/contrib/hbmsql/tests/dbf2msql.prg rename to harbour/examples/hbmsql/tests/dbf2msql.prg diff --git a/harbour/contrib/hbmsql/tests/hbmsql.hbc b/harbour/examples/hbmsql/tests/hbmsql.hbc similarity index 100% rename from harbour/contrib/hbmsql/tests/hbmsql.hbc rename to harbour/examples/hbmsql/tests/hbmsql.hbc diff --git a/harbour/contrib/hbmsql/tests/test.prg b/harbour/examples/hbmsql/tests/test.prg similarity index 100% rename from harbour/contrib/hbmsql/tests/test.prg rename to harbour/examples/hbmsql/tests/test.prg diff --git a/harbour/contrib/hbmsql/tmsql.prg b/harbour/examples/hbmsql/tmsql.prg similarity index 100% rename from harbour/contrib/hbmsql/tmsql.prg rename to harbour/examples/hbmsql/tmsql.prg diff --git a/harbour/make_gnu.bat b/harbour/make_gnu.bat index 745e845ec9..69dd7911a4 100644 --- a/harbour/make_gnu.bat +++ b/harbour/make_gnu.bat @@ -5,26 +5,16 @@ @echo off rem --------------------------------------------------------------- -rem This is a generic template file, if it doesn't fit your own needs -rem please DON'T MODIFY IT. -rem -rem Instead, make a local copy and modify that one, or make a call to -rem this batch file from your customized one. [vszakats] -rem --------------------------------------------------------------- - -rem --------------------------------------------------------------- -rem Template to initialize the environment before starting -rem the GNU make system for Harbour -rem -rem For further information about the GNU make system please -rem check doc/gmake.txt -rem rem Copyright 1999-2009 Viktor Szakats (harbour.01 syenar.hu) rem See COPYING for licensing terms. +rem +rem Initialize environment for GNU Make system to build Harbour +rem +rem For further information about the GNU Make system please +rem check doc/gmake.txt rem --------------------------------------------------------------- -rem Setup defaults. - +rem Setup defaults if "%HB_ARCHITECTURE%" == "" if not "%WINDIR%" == "" set HB_ARCHITECTURE=win if "%HB_ARCHITECTURE%" == "" set HB_ARCHITECTURE=dos if "%HB_COMPILER%" == "" if not "%WINDIR%" == "" goto WIN_AUTODETECT @@ -34,7 +24,7 @@ if "%HB_COMPILER%" == "" set HB_COMPILER=djgpp if "%HB_INSTALL_PREFIX%" == "" if "%OS%" == "Windows_NT" set HB_INSTALL_PREFIX=%~dp0 - rem Set to constant value to be consistent with the non-GNU make files. + rem Set to constant value. if "%HB_BIN_INSTALL%" == "" set HB_BIN_INSTALL=%HB_INSTALL_PREFIX%\bin if "%HB_LIB_INSTALL%" == "" set HB_LIB_INSTALL=%HB_INSTALL_PREFIX%\lib if "%HB_INC_INSTALL%" == "" set HB_INC_INSTALL=%HB_INSTALL_PREFIX%\include @@ -46,8 +36,6 @@ if "%HB_COMPILER%" == "" set HB_COMPILER=djgpp if not exist %HB_INC_INSTALL%\*.* md %HB_INC_INSTALL% if not exist %HB_DOC_INSTALL%\*.* md %HB_DOC_INSTALL% -:START - if "%HB_ARCHITECTURE%" == "" goto BAD_ARCH if "%HB_COMPILER%" == "" goto BAD_COMP @@ -145,7 +133,7 @@ if "%HB_COMPILER%" == "" set HB_COMPILER=djgpp set _HB_PATH= rem --------------------------------------------------------------- - rem Start the GNU make system + rem Start the GNU Make system rem --------------------------------------------------------------- rem Special build mode when HB_BUILD_DLL=yes on Windows platform. diff --git a/harbour/utils/hbmk2/hbmk2.prg b/harbour/utils/hbmk2/hbmk2.prg index 77ea6aa830..85b26eab79 100644 --- a/harbour/utils/hbmk2/hbmk2.prg +++ b/harbour/utils/hbmk2/hbmk2.prg @@ -1813,7 +1813,14 @@ FUNCTION hbmk( aArgs, /* @ */ lPause, /* @ */ lUTF8 ) /* Decide about working dir */ IF ! lStopAfterInit IF hbmk[ _HBMK_lINC ] - DEFAULT cWorkDir TO FN_DirGet( s_cPROGNAME ) + _WORKDIR_DEF_ + /* NOTE: We store -hbdyn objects in different dirs by default as - for Windows + platforms - they're always built using different compilation options + than normal targets. [vszakats] */ + IF lCreateDyn .AND. hbmk[ _HBMK_cARCH ] $ "win|wce" + DEFAULT cWorkDir TO FN_DirGet( s_cPROGNAME ) + _WORKDIR_DEF_ + hb_osPathSeparator() + "hbdyn" + ELSE + DEFAULT cWorkDir TO FN_DirGet( s_cPROGNAME ) + _WORKDIR_DEF_ + ENDIF AAdd( hbmk[ _HBMK_aOPTPRG ], "-o" + cWorkDir + hb_osPathSeparator() ) /* NOTE: Ending path sep is important. */ IF ! DirBuild( cWorkDir ) hbmk_OutErr( hbmk, hb_StrFormat( I_( "Error: Working directory cannot be created: %1$s" ), cWorkDir ) )