2009-08-20 14:16 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
* config/global.mk
* INSTALL
* bin/hb-mkdyn.sh
* bin/hb-mkdyn.bat
+ Added HB_USER_DFLAGS to add custom linker flags to .dll link command.
(just like in hbmk2)
- In hb-mkdyn.sh HB_USER_LDFLAGS deleted, now HB_USER_DFLAGS replaced it.
(HB_USER_LDFLAGS was missing from darwin link cmd)
* bin/hb-mkdyn.bat
! HB_DLLLIBS -> HB_DLLIBS
* config/global.mk
+ Added HB_DLLIBS to list of misc custom settings.
* INSTALL
+ Revision of OPTIONS AVAILABLE WHEN BUILDING HARBOUR section.
! Typo.
This commit is contained in:
@@ -17,6 +17,26 @@
|
||||
past entries belonging to author(s): Viktor Szakats.
|
||||
*/
|
||||
|
||||
2009-08-20 14:16 UTC+0200 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* config/global.mk
|
||||
* INSTALL
|
||||
* bin/hb-mkdyn.sh
|
||||
* bin/hb-mkdyn.bat
|
||||
+ Added HB_USER_DFLAGS to add custom linker flags to .dll link command.
|
||||
(just like in hbmk2)
|
||||
- In hb-mkdyn.sh HB_USER_LDFLAGS deleted, now HB_USER_DFLAGS replaced it.
|
||||
(HB_USER_LDFLAGS was missing from darwin link cmd)
|
||||
|
||||
* bin/hb-mkdyn.bat
|
||||
! HB_DLLLIBS -> HB_DLLIBS
|
||||
|
||||
* config/global.mk
|
||||
+ Added HB_DLLIBS to list of misc custom settings.
|
||||
|
||||
* INSTALL
|
||||
+ Revision of OPTIONS AVAILABLE WHEN BUILDING HARBOUR section.
|
||||
! Typo.
|
||||
|
||||
2009-08-20 13:32 UTC+0200 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
|
||||
* harbour/include/hbthread.h
|
||||
! do not include <process.h> in WinCE builds
|
||||
|
||||
@@ -289,55 +289,68 @@ OPTIONS AVAILABLE WHEN BUILDING HARBOUR
|
||||
-------
|
||||
- HB_COMPILER Override C compiler autodetection
|
||||
- HB_ARCHITECTURE Override platform autodetection
|
||||
See this secion for possible values:
|
||||
See this section for possible values:
|
||||
SUPPORTED C COMPILERS UNDER DIFFERENT PLATFORMS
|
||||
|
||||
- HB_USER_PRGFLAGS User Harbour compiler options
|
||||
- HB_USER_CFLAGS User C compiler options
|
||||
- HB_USER_LDFLAGS User linker options for executables
|
||||
- HB_USER_AFLAGS User linker options for libraries
|
||||
- HB_USER_DFLAGS User linker options for dynamic libraries
|
||||
|
||||
- HB_INSTALL_PREFIX Target root directory to install Harbour files.
|
||||
This will default to Harbour source tree.
|
||||
- HB_BIN_INSTALL Target directory to install executables
|
||||
- HB_LIB_INSTALL Target directory to install libraries
|
||||
- HB_INC_INSTALL Target directory to install language headers
|
||||
- HB_DOC_INSTALL Target directory to install documentation
|
||||
This will default to Harbour source tree on
|
||||
non-*nix systems. On *nix systems the default
|
||||
is set to /usr/local/ or $(PREFIX) if specified,
|
||||
and /usr/local/harbour-<arch>-<comp> for
|
||||
cross-builds. It's always set to /pkg/<arch>/<comp>
|
||||
when HB_BUILD_PKG is set to 'yes'.
|
||||
|
||||
- HB_BIN_INSTALL Override directory to install executables
|
||||
- HB_LIB_INSTALL Override directory to install libraries
|
||||
- HB_INC_INSTALL Override directory to install language headers
|
||||
- HB_DOC_INSTALL Override directory to install documentation
|
||||
|
||||
Special
|
||||
-------
|
||||
- HB_BUILD_NAME=<name> Create named build. This allows to keep
|
||||
- HB_BUILD_NAME=[<name>] Create named build. This allows to keep
|
||||
multiple builds in parallel for any given
|
||||
platform/compiler. F.e. debug / release.
|
||||
NOTE: In current implementation it's
|
||||
appended to compiler directory name, so all
|
||||
filesystem/platform name rules and limits
|
||||
apply. It's valid to use (back)slashes though.
|
||||
- HB_BUILD_PKG=yes Create release packages (requires 'clean install').
|
||||
- HB_BUILD_DLL=no Don't create Harbour .dlls.
|
||||
- HB_BUILD_IMPLIB=yes Create import libraries for external .dll dependencies.
|
||||
- HB_BUILD_DEBUG=yes Create a debug build.
|
||||
- HB_BUILD_OPTIM=no Disable C compiler optimizations.
|
||||
- HB_BUILD_UNICODE=yes Create Unicode build (Windows/Windows CE).
|
||||
- HB_BUILD_PKG=yes Create release package. Default: no
|
||||
Requires 'clean install' in root source dir.
|
||||
(currently on Windows/Windows CE/DOS)
|
||||
- HB_BUILD_DLL=no Create Harbour .dlls. Default: yes
|
||||
- HB_BUILD_IMPLIB=yes Create import libraries for external .dll
|
||||
dependencies. Default: no
|
||||
- HB_BUILD_DEBUG=yes Create a debug build. Default: no
|
||||
- HB_BUILD_OPTIM=no Enable C compiler optimizations. Default: yes
|
||||
- HB_BUILD_UNICODE=yes Create Unicode build (on Windows/Windows CE).
|
||||
Default: no
|
||||
- HB_BUILD_MODE=[cpp|c] Changes default build mode to C++ or C.
|
||||
Default is C, except for msvc* and watcom
|
||||
compilers.
|
||||
- HB_CONTRIBLIBS=no Don't build any contrib libraries.
|
||||
Default: c, except for msvc* and watcom
|
||||
compilers where it's cpp.
|
||||
- HB_CONTRIBLIBS=no Don't build any contrib libraries. Default: yes
|
||||
- HB_CONTRIBLIBS=[<list>] Build space separated <list> of contrib
|
||||
libraries. Build all if left empty.
|
||||
- HB_CONTRIB_ADDONS=<list> Build space separated <list> of additional
|
||||
libraries stored in the contrib directory.
|
||||
- HB_EXTERNALLIBS=no Don't build any external libraries.
|
||||
- HB_EXTERNALLIBS=no Don't build any external libraries. Default: yes
|
||||
- HB_EXTERNALLIBS=[<list>] Build space separated <list> of external
|
||||
libraries. Build all if left empty.
|
||||
- HB_EXTERNAL_ADDONS=<list> Build space separated <list> of additional
|
||||
libraries stored in the external directory.
|
||||
- HB_VISUALC_VER_PRE80=yes Set this if you're using a pre-8.0
|
||||
(= pre-MSVS 2005) version of MSVC compiler.
|
||||
- HB_REBUILD_PARSER=yes To rebuild the language parsers. Typically
|
||||
Default: no
|
||||
- HB_REBUILD_PARSER=yes Rebuild language parser sources. Typically
|
||||
you only need this if your are Harbour core
|
||||
developer modifying the parser.
|
||||
This requires GNU Bison 1.28 or upper in PATH.
|
||||
developer modifying grammar rules (.y).
|
||||
Requires GNU Bison 1.28 or upper in PATH.
|
||||
Default: no
|
||||
|
||||
Cross building
|
||||
--------------
|
||||
|
||||
@@ -89,8 +89,8 @@ if "%HB_ARCHITECTURE%_%HB_COMPILER%" == "win_iccia64" set _BIN_LINK=xilink
|
||||
if "%HB_ARCHITECTURE%" == "win" set _SYSLIBS=user32.lib ws2_32.lib advapi32.lib gdi32.lib
|
||||
if "%HB_ARCHITECTURE%" == "wce" set _SYSLIBS=coredll.lib ws2.lib
|
||||
|
||||
echo ! Making %_DST_NAME_ST%.dll... && %_BIN_LINK% /nologo /dll /subsystem:console /out:"%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll" @"%_LIST_ST%" %_SYSLIBS% %HB_DLLLIBS%
|
||||
echo ! Making %_DST_NAME_MT%.dll... && %_BIN_LINK% /nologo /dll /subsystem:console /out:"%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll" @"%_LIST_MT%" %_SYSLIBS% %HB_DLLLIBS%
|
||||
echo ! Making %_DST_NAME_ST%.dll... && %_BIN_LINK% /nologo /dll /subsystem:console %HB_USER_DFLAGS% /out:"%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll" @"%_LIST_ST%" %_SYSLIBS% %HB_DLLIBS%
|
||||
echo ! Making %_DST_NAME_MT%.dll... && %_BIN_LINK% /nologo /dll /subsystem:console %HB_USER_DFLAGS% /out:"%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll" @"%_LIST_MT%" %_SYSLIBS% %HB_DLLIBS%
|
||||
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_ST%.lib"
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_MT%.lib"
|
||||
@@ -122,8 +122,8 @@ del "%_LIST_MT%"
|
||||
if "%HB_ARCHITECTURE%" == "win" set _SYSLIBS=-luser32 -lws2_32 -ladvapi32 -lgdi32
|
||||
if "%HB_ARCHITECTURE%" == "wce" set _SYSLIBS=-lcoredll -lws2
|
||||
|
||||
echo ! Making %_DST_NAME_ST%.dll... && %HB_CCPREFIX%gcc -shared -o "%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll" "%_LIST_ST%_" %HB_USER_LDFLAGS% %_SYSLIBS% %HB_DLLLIBS% -Wl,--output-def,"%HB_BIN_INSTALL%\%_DST_NAME_ST%.def"
|
||||
echo ! Making %_DST_NAME_MT%.dll... && %HB_CCPREFIX%gcc -shared -o "%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll" "%_LIST_MT%_" %HB_USER_LDFLAGS% %_SYSLIBS% %HB_DLLLIBS% -Wl,--output-def,"%HB_BIN_INSTALL%\%_DST_NAME_MT%.def"
|
||||
echo ! Making %_DST_NAME_ST%.dll... && %HB_CCPREFIX%gcc -shared %HB_USER_DFLAGS% -o "%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll" "%_LIST_ST%_" %HB_USER_LDFLAGS% %_SYSLIBS% %HB_DLLIBS% -Wl,--output-def,"%HB_BIN_INSTALL%\%_DST_NAME_ST%.def"
|
||||
echo ! Making %_DST_NAME_MT%.dll... && %HB_CCPREFIX%gcc -shared %HB_USER_DFLAGS% -o "%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll" "%_LIST_MT%_" %HB_USER_LDFLAGS% %_SYSLIBS% %HB_DLLIBS% -Wl,--output-def,"%HB_BIN_INSTALL%\%_DST_NAME_MT%.def"
|
||||
|
||||
rem ,--out-implib,"%HB_LIB_INSTALL%\lib%_DST_NAME_ST%.a"
|
||||
rem ,--out-implib,"%HB_LIB_INSTALL%\lib%_DST_NAME_MT%.a"
|
||||
@@ -145,8 +145,8 @@ call :MAKE_LISTS
|
||||
echo. , "%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll",, cw32mt.lib import32.lib %HB_DLLIBS% >> "%_LIST_ST%"
|
||||
echo. , "%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll",, cw32mt.lib import32.lib %HB_DLLIBS% >> "%_LIST_MT%"
|
||||
|
||||
echo ! Making %_DST_NAME_ST%.dll... && ilink32 -q -Gn -C -aa -Tpd -Gi -x c0d32.obj @%_LIST_ST%
|
||||
echo ! Making %_DST_NAME_MT%.dll... && ilink32 -q -Gn -C -aa -Tpd -Gi -x c0d32.obj @%_LIST_MT%
|
||||
echo ! Making %_DST_NAME_ST%.dll... && ilink32 -q -Gn -C -aa -Tpd -Gi -x %HB_USER_DFLAGS% c0d32.obj @%_LIST_ST%
|
||||
echo ! Making %_DST_NAME_MT%.dll... && ilink32 -q -Gn -C -aa -Tpd -Gi -x %HB_USER_DFLAGS% c0d32.obj @%_LIST_MT%
|
||||
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_ST%.lib"
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_MT%.lib"
|
||||
@@ -165,8 +165,8 @@ set HB_OBJ_PREF=FILE '
|
||||
set HB_OBJ_POST='
|
||||
call :MAKE_LISTS
|
||||
|
||||
echo ! Making %_DST_NAME_ST%.dll... && wlink OP QUIET SYS NT_DLL OP IMPLIB NAME '%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll' @'%_LIST_ST%' LIB user32.lib, ws2_32.lib, advapi32.lib, gdi32.lib
|
||||
echo ! Making %_DST_NAME_MT%.dll... && wlink OP QUIET SYS NT_DLL OP IMPLIB NAME '%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll' @'%_LIST_MT%' LIB user32.lib, ws2_32.lib, advapi32.lib, gdi32.lib
|
||||
echo ! Making %_DST_NAME_ST%.dll... && wlink OP QUIET SYS NT_DLL %HB_USER_DFLAGS% OP IMPLIB NAME '%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll' @'%_LIST_ST%' LIB user32.lib, ws2_32.lib, advapi32.lib, gdi32.lib
|
||||
echo ! Making %_DST_NAME_MT%.dll... && wlink OP QUIET SYS NT_DLL %HB_USER_DFLAGS% OP IMPLIB NAME '%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll' @'%_LIST_MT%' LIB user32.lib, ws2_32.lib, advapi32.lib, gdi32.lib
|
||||
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_ST%.lib"
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_MT%.lib"
|
||||
@@ -186,8 +186,8 @@ call :MAKE_LISTS
|
||||
if "%HB_ARCHITECTURE%" == "win" set _SYSLIBS=user32.lib ws2_32.lib advapi32.lib gdi32.lib
|
||||
if "%HB_ARCHITECTURE%" == "wce" set _SYSLIBS=coredll.lib ws2.lib
|
||||
|
||||
echo ! Making %_DST_NAME_ST%.dll... && polink /nologo /dll /out:"%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll" @%_LIST_ST% %_SYSLIBS% %HB_DLLLIBS%
|
||||
echo ! Making %_DST_NAME_MT%.dll... && polink /nologo /dll /out:"%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll" @%_LIST_MT% %_SYSLIBS% %HB_DLLLIBS%
|
||||
echo ! Making %_DST_NAME_ST%.dll... && polink /nologo /dll %HB_USER_DFLAGS% /out:"%HB_BIN_INSTALL%\%_DST_NAME_ST%.dll" @%_LIST_ST% %_SYSLIBS% %HB_DLLIBS%
|
||||
echo ! Making %_DST_NAME_MT%.dll... && polink /nologo /dll %HB_USER_DFLAGS% /out:"%HB_BIN_INSTALL%\%_DST_NAME_MT%.dll" @%_LIST_MT% %_SYSLIBS% %HB_DLLIBS%
|
||||
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_ST%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_ST%.lib"
|
||||
if exist "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" move /Y "%HB_BIN_INSTALL%\%_DST_NAME_MT%.lib" "%HB_LIB_INSTALL%\%_DST_NAME_MT%.lib"
|
||||
|
||||
@@ -127,7 +127,7 @@ if [ "${SLIB_EXT}" = ".dylib" ]; then
|
||||
FULLNAME="${BASE}.${VERSION}${SLIB_EXT}"
|
||||
libtool -dynamic -install_name "${BASE}${SLIB_EXT}" \
|
||||
-compatibility_version ${MAJOR}.${MINOR} -current_version ${VERSION} \
|
||||
-flat_namespace -undefined warning -multiply_defined suppress -single_module \
|
||||
-flat_namespace -undefined warning -multiply_defined suppress -single_module ${HB_USER_DFLAGS} \
|
||||
-o "${DSTDIR}/${FULLNAME}" "$@" && \
|
||||
ln -sf "${FULLNAME}" "${DSTDIR}${BASE}.${MAJOR}${SLIB_EXT}" && \
|
||||
ln -sf "${FULLNAME}" "${DSTDIR}${BASE}${SLIB_EXT}"
|
||||
@@ -139,7 +139,7 @@ elif [ "${SLIB_EXT}" = ".dll" ]; then
|
||||
SYSLIBS="-luser32 -lws2_32 -ladvapi32 -lgdi32"
|
||||
fi
|
||||
# -Wl,--output-def,testdll.def,--out-implib,libtestdll.a
|
||||
${HB_CCPREFIX}gcc -shared -o "${FULLNAME}" $OBJLST ${linker_options} ${HB_USER_LDFLAGS} ${SYSLIBS} ${HB_DLLIBS} && \
|
||||
${HB_CCPREFIX}gcc -shared -o "${FULLNAME}" $OBJLST ${linker_options} ${HB_USER_DFLAGS} ${SYSLIBS} ${HB_DLLIBS} && \
|
||||
cd "${dir}" && \
|
||||
rm -f "${DSTDIR}${FULLNAME}" && \
|
||||
mv -f "${OTMPDIR}/${FULLNAME}" "${DSTDIR}${FULLNAME}"
|
||||
@@ -147,7 +147,7 @@ else
|
||||
#FULLNAME="${BASE}-${VERSION}${SLIB_EXT}"
|
||||
#FULLNAME="${BASE}{SLIB_EXT}.${VERSION}"
|
||||
FULLNAME="${LIB_NAME}${SLIB_EXT}"
|
||||
${HB_CCPREFIX}gcc -shared -fPIC -o "${FULLNAME}" $OBJLST ${linker_options} ${HB_USER_LDFLAGS} && \
|
||||
${HB_CCPREFIX}gcc -shared -fPIC -o "${FULLNAME}" $OBJLST ${linker_options} ${HB_USER_DFLAGS} && \
|
||||
cd "${dir}" && \
|
||||
mv -f "${OTMPDIR}/${FULLNAME}" "${DSTDIR}${FULLNAME}"
|
||||
fi
|
||||
|
||||
@@ -238,6 +238,7 @@ ifeq ($(HB_INIT_DONE),)
|
||||
# HB_GPM_NOICE_DISABLE -> HB_USER_CFLAGS=-DHB_GPM_NOICE_DISABLE
|
||||
# HB_GT_CRS_BCEHACK -> HB_USER_CFLAGS=-DHB_GT_CRS_BCEHACK
|
||||
# HB_NCURSES_194 -> HB_USER_CFLAGS=-DHB_NCURSES_194
|
||||
# HB_DLLIBS -> ?
|
||||
# Macros:
|
||||
# -DHB_PCRE_REGEX, -DHB_POSIX_REGEX, -DHB_EXT_ZLIB, -DHB_HAS_GPM
|
||||
|
||||
@@ -254,6 +255,9 @@ ifeq ($(HB_INIT_DONE),)
|
||||
ifneq ($(HB_USER_AFLAGS),)
|
||||
$(info ! HB_USER_AFLAGS: $(HB_USER_AFLAGS))
|
||||
endif
|
||||
ifneq ($(HB_USER_DFLAGS),)
|
||||
$(info ! HB_USER_AFLAGS: $(HB_USER_DFLAGS))
|
||||
endif
|
||||
ifneq ($(HB_INSTALL_PREFIX),)
|
||||
$(info ! HB_INSTALL_PREFIX: $(HB_INSTALL_PREFIX))
|
||||
endif
|
||||
|
||||
Reference in New Issue
Block a user