diff --git a/harbour/ChangeLog b/harbour/ChangeLog
index 8bea293936..1b907cbdf0 100644
--- a/harbour/ChangeLog
+++ b/harbour/ChangeLog
@@ -8,6 +8,34 @@
2009-12-31 13:59 UTC+0100 Foo Bar (foo.bar foobar.org)
*/
+2009-03-04 01:46 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
+ * INSTALL
+ * make_gnu.bat
+ - 'msvc' is no longer the default choice for win.
+ HB_COMPILER must always be specified.
+
+ * mpkg_win.bat
+ + Removes tmp install dir before creating the build.
+ + Added support for MinGW.
+ + Added creation of .zip packages. (Info-ZIP zip.exe
+ is required).
+
+ * make_gnu.sh
+ * INSTALL
+ + on win/dos/os2 systems it will create HB_*_INSTALL dirs
+ automatically (sync with make_gnu.bat).
+ + on dos/os2 it will also automatically set HB_DOC_INSTALL.
+ + on win/dos/os2 it will automatically convert
+ HB_INSTALL_PREFIX and HB_*_INSTALL to use forward slashes.
+
+ * utils/hbmk2/hbmk2.prg
+ + Added gtnul to standard list of GTs.
+ Attempt to solve the problem reported by Barry Jackson.
+ Please test if this solves anything.
+
+ * doc/Makefile
+ ! Deleted files removed.
+
2009-03-04 00:53 UTC+0100 Viktor Szakats (harbour.01 syenar hu)
* utils/hbmk2/hbmk2.prg
! Fixed problem reported by Istvan Bisz.
diff --git a/harbour/INSTALL b/harbour/INSTALL
index 6c987f0642..4ecbeb4eee 100644
--- a/harbour/INSTALL
+++ b/harbour/INSTALL
@@ -48,9 +48,6 @@ HOW TO BUILD AND INSTALL HARBOUR
> hello
You should see 'Hello world!' on screen.
- NOTE: You have to use forwards slashes in
, and
- msys style drive notation: /c/ (means C:)
-
Windows with other compilers
----------------------------
Platform specific prerequisites:
@@ -73,7 +70,7 @@ HOW TO BUILD AND INSTALL HARBOUR
- Rename mingw32-make.exe to make.exe and put it in
your PATH _before_ your compiler tools.
- > set HB_COMPILER=<[msvc]|bcc|owatcom|...>
+ > set HB_COMPILER=
> set HB_INSTALL_PREFIX=
> make_gnu.bat install
diff --git a/harbour/doc/Makefile b/harbour/doc/Makefile
index 47f499e989..b98f2d50fc 100644
--- a/harbour/doc/Makefile
+++ b/harbour/doc/Makefile
@@ -13,19 +13,14 @@ DOC_FILES=\
codestyl.txt \
destruct.txt \
dirstruc.txt \
- funclist.txt \
gmake.txt \
gtapi.txt \
- hbmake.txt \
hdr_tpl.txt \
howtobld.txt \
howtobsd.txt \
- howtomak.txt \
howtorel.txt \
howtosvn.txt \
- hrb_faq.txt \
inet.txt \
- lang_id.txt \
license.txt \
linux1st.txt \
pcode.txt \
diff --git a/harbour/make_gnu.bat b/harbour/make_gnu.bat
index 4d51414ea4..e299225186 100644
--- a/harbour/make_gnu.bat
+++ b/harbour/make_gnu.bat
@@ -27,7 +27,7 @@ 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%" == "" set HB_COMPILER=msvc
+if "%HB_COMPILER%" == "" if not "%WINDIR%" == "" goto HELP
if "%HB_COMPILER%" == "" set HB_COMPILER=djgpp
rem Compatibility
diff --git a/harbour/make_gnu.sh b/harbour/make_gnu.sh
index fbb40b6976..ef9e6f7592 100755
--- a/harbour/make_gnu.sh
+++ b/harbour/make_gnu.sh
@@ -113,6 +113,26 @@ then
export HB_USER_CFLAGS="$HB_USER_CFLAGS -fPIC"
fi
+if [ "$HB_ARCHITECTURE" == "win" ] || \
+ [ "$HB_ARCHITECTURE" == "dos" ] || \
+ [ "$HB_ARCHITECTURE" == "os2" ]; then
+ if [ -n "$HB_INSTALL_PREFIX" ]; then
+ export HB_INSTALL_PREFIX="${HB_INSTALL_PREFIX//\\//}"
+ fi
+ if [ -n "$HB_BIN_INSTALL" ]; then
+ export HB_BIN_INSTALL="${HB_BIN_INSTALL//\\//}"
+ fi
+ if [ -n "$HB_LIB_INSTALL" ]; then
+ export HB_LIB_INSTALL="${HB_LIB_INSTALL//\\//}"
+ fi
+ if [ -n "$HB_INC_INSTALL" ]; then
+ export HB_INC_INSTALL="${HB_INC_INSTALL//\\//}"
+ fi
+ if [ -n "$HB_DOC_INSTALL" ]; then
+ export HB_DOC_INSTALL="${HB_DOC_INSTALL//\\//}"
+ fi
+fi
+
[ -z "$HB_INSTALL_PREFIX" ] && [ -n "$PREFIX" ] && export HB_INSTALL_PREFIX="$PREFIX"
[ -z "$HB_INSTALL_PREFIX" ] && export HB_INSTALL_PREFIX=/usr/local
@@ -130,8 +150,17 @@ esac
if [ -z "$HB_BIN_INSTALL" ]; then export HB_BIN_INSTALL=$HB_INSTALL_PREFIX/bin; fi
if [ -z "$HB_LIB_INSTALL" ]; then export HB_LIB_INSTALL=$HB_INSTALL_PREFIX/lib$hb_instsubdir; fi
if [ -z "$HB_INC_INSTALL" ]; then export HB_INC_INSTALL=$HB_INSTALL_PREFIX/include$hb_instsubdir; fi
-if [ -z "$HB_DOC_INSTALL" ] && [ "${HB_COMPILER}" == "mingw" ]; then export HB_DOC_INSTALL=$HB_INSTALL_PREFIX/doc; fi
+if [ "$HB_ARCHITECTURE" == "win" ] || \
+ [ "$HB_ARCHITECTURE" == "dos" ] || \
+ [ "$HB_ARCHITECTURE" == "os2" ]; then
+ if [ -z "$HB_DOC_INSTALL" ]; then export HB_DOC_INSTALL=$HB_INSTALL_PREFIX/doc; fi
+ mkdir -p $HB_BIN_INSTALL
+ mkdir -p $HB_LIB_INSTALL
+ mkdir -p $HB_INC_INSTALL
+ mkdir -p $HB_DOC_INSTALL
+ echo !!! $HB_BIN_INSTALL
+fi
if [ -z "$HB_ARCHITECTURE" ]; then
echo "Error: HB_ARCHITECTURE is not set."
diff --git a/harbour/mpkg_win.bat b/harbour/mpkg_win.bat
index 753375620d..3265d0ebeb 100644
--- a/harbour/mpkg_win.bat
+++ b/harbour/mpkg_win.bat
@@ -15,6 +15,7 @@ rem - Windows NT or upper
rem - NullSoft Installer installed (NSIS)
rem http://nsis.sourceforge.net
rem - makensis.exe (part of NSIS) in PATH
+rem - Info-ZIP zip.exe in PATH.
rem - HB_COMPILER envvar configured (see INSTALL doc)
rem - C compiler and GNU Make configured (see INSTALL doc)
rem ---------------------------------------------------------------
@@ -23,12 +24,37 @@ if not "%OS%" == "Windows_NT" goto END
setlocal
-set HB_INSTALL_PREFIX=%~dp0_hb_install_temp
-set HB_BUILD_DLL=yes
-call make_gnu.bat
+rem ; Basic setup
set HB_VERSION=1.1.0dev
+set HB_ARCHITECTURE=win
+set HB_PKGNAME=harbour-%HB_VERSION%-%HB_ARCHITECTURE%-%HB_COMPILER%
+set HB_DIRNAME=harbour-%HB_COMPILER%
+
+rem ; Dir setup
+set HB_INSTALL_BASE=%~dp0_hb_install_temp
+set HB_INSTALL_PREFIX=%HB_INSTALL_BASE%\%HB_DIRNAME%
+set HB_BIN_INSTALL=%HB_INSTALL_PREFIX%\bin
+set HB_LIB_INSTALL=%HB_INSTALL_PREFIX%\lib
+set HB_INC_INSTALL=%HB_INSTALL_PREFIX%\include
+set HB_DOC_INSTALL=%HB_INSTALL_PREFIX%\doc
+
+rem ; Cleanup
+if exist %HB_INSTALL_BASE% rmdir /q /s %HB_INSTALL_BASE%
+
+rem ; Build
+if "%HB_COMPILER%" == "mingw" sh make_gnu.sh install
+if not "%HB_COMPILER%" == "mingw" set HB_BUILD_DLL=yes
+if not "%HB_COMPILER%" == "mingw" call make_gnu.bat
+
+rem ; Installer
makensis.exe %~dp0mpkg_win.nsi
-if "%1" == "--deltemp" rmdir /q /s %HB_INSTALL_PREFIX%
+
+rem ; .zip packages
+if exist %HB_PKGNAME%.zip del %HB_PKGNAME%.zip
+zip -X -r -o %HB_PKGNAME%.zip %HB_INSTALL_BASE%\*
+
+rem ; Cleanup
+if "%1" == "--deltemp" rmdir /q /s %HB_INSTALL_BASE%
endlocal
diff --git a/harbour/mpkg_win.nsi b/harbour/mpkg_win.nsi
index d6bfb538c2..f3d01ec7be 100644
--- a/harbour/mpkg_win.nsi
+++ b/harbour/mpkg_win.nsi
@@ -29,9 +29,9 @@ CRCCheck on
Name "Harbour Project"
; The file to write
-OutFile "harbour-$%HB_VERSION%-$%HB_ARCHITECTURE%-$%HB_COMPILER%.exe"
+OutFile "$%HB_PKGNAME%.exe"
-InstallDir C:\harbour-$%HB_COMPILER%
+InstallDir C:\$%HB_DIRNAME%
;--------------------------------
; Interface Settings
diff --git a/harbour/utils/hbmk2/hbmk2.prg b/harbour/utils/hbmk2/hbmk2.prg
index 9a7a2149f7..56d08e0e3d 100644
--- a/harbour/utils/hbmk2/hbmk2.prg
+++ b/harbour/utils/hbmk2/hbmk2.prg
@@ -139,6 +139,7 @@ FUNCTION Main( ... )
"hbextern" }
LOCAL aLIB_BASE_GT := {;
+ "gtnul" ,;
"gtcgi" ,;
"gtpca" ,;
"gtstd" }