gbuildification of expat

Two different xmlparse libraries are created: ascii_expat_xmlparse and
expat_xmlparse. One without -DXML_UNICODE and one with. Source file are
duplicated and renamed with gb_UnpackedTarball_set_post_action function
to be able to add artifacts twice to gbuild machinery.

On windows 64 bit additional two librares are created: expat_xmlparse_x64 and
expat_xmltok_x64. That is due the problem with shell/shlxthandler (comment):
------------------------------------------------------
use UNICODE only because shell/shlxthandler
doesn't link against ascii_expat_xmlparse
------------------------------------------------------

Include files are delivered to $(OUTDIR)/inc/external/expat
now and not to $(OUTDIR)/inc/external any more.
set_include call is added in RepositoryExternal.mk.

To define dependency between StaticLibrary and ExternalProject
new function was introduced: gb_StaticLibrary_use_external_project.

Change-Id: I3b3aa40f39ef82c70f6f28790b582c83e48bdf76
This commit is contained in:
David Ostrovsky 2012-10-12 12:28:11 -07:00 committed by Michael Stahl
parent 7f96cec269
commit 2ffde7b171
27 changed files with 402 additions and 190 deletions

View File

@ -73,6 +73,7 @@ editeng\
embeddedobj\
embedserv\
eventattacher\
expat\
extensions\
extras\
fileaccess\
@ -210,7 +211,6 @@ cppunit\
crashrep\
curl\
epm\
expat\
external\
gdk-pixbuf\
gettext\

View File

@ -237,11 +237,18 @@ $(eval $(call gb_Helper_register_static_libraries,PLAINLIBS, \
ascii_expat_xmlparse \
expat_xmlparse \
expat_xmltok \
expat_xmlparse_x64 \
expat_xmltok_x64 \
))
define gb_LinkTarget__use_expat
$(if $(2),,$(error gb_LinkTarget__use_expat needs additional parameter))
$(call gb_LinkTarget_set_include,$(1),\
-I$(OUTDIR)/inc/external/expat \
$$(INCLUDE) \
)
$(if $(filter-out ascii_expat_xmlparse,$(2)),\
$(call gb_LinkTarget_add_defs,$(1),\
-DXML_UNICODE \
@ -249,7 +256,7 @@ $(if $(filter-out ascii_expat_xmlparse,$(2)),\
$(call gb_LinkTarget_use_static_libraries,$(1),\
$(2) \
expat_xmltok \
$(3)\
)
endef
@ -258,12 +265,17 @@ endif # SYSTEM_EXPAT
# now define 2 wrappers that select which internal static library to use...
define gb_LinkTarget__use_expat_utf8
$(call gb_LinkTarget__use_expat,$(1),ascii_expat_xmlparse)
$(call gb_LinkTarget__use_expat,$(1),ascii_expat_xmlparse,expat_xmltok)
endef
define gb_LinkTarget__use_expat_utf16
$(call gb_LinkTarget__use_expat,$(1),expat_xmlparse)
$(call gb_LinkTarget__use_expat,$(1),expat_xmlparse,expat_xmltok)
endef
define gb_LinkTarget__use_expat_utf16_x64
$(call gb_LinkTarget__use_expat,$(1),expat_xmlparse_x64,expat_xmltok_x64)
endef

View File

@ -523,6 +523,7 @@ export JFREEREPORT_LIBREPOSITORY_TARBALL=@JFREEREPORT_LIBREPOSITORY_TARBALL@
export JFREEREPORT_LIBSERIALIZER_TARBALL=@JFREEREPORT_LIBSERIALIZER_TARBALL@
export JFREEREPORT_FLOW_ENGINE_TARBALL=@JFREEREPORT_FLOW_ENGINE_TARBALL@
export JFREEREPORT_LIBLAYOUT_TARBALL=@JFREEREPORT_LIBLAYOUT_TARBALL@
export EXPAT_TARBALL=@EXPAT_TARBALL@
export SAL_ENABLE_FILE_LOCKING=1
export SCPDEFS=@SCPDEFS@
export SERVLETAPI_JAR=@SERVLETAPI_JAR@

View File

@ -6926,9 +6926,11 @@ if test "$with_system_expat" = "yes"; then
else
AC_MSG_RESULT([internal])
SYSTEM_EXPAT=NO
EXPAT_TARBALL="dd7dab7a5fea97d2a6a43f511449b7cd-expat-2.1.0.tar.gz"
BUILD_TYPE="$BUILD_TYPE EXPAT"
fi
AC_SUBST(SYSTEM_EXPAT)
AC_SUBST(EXPAT_TARBALL)
AC_SUBST([MINGW_EXPAT_DLL])
dnl ===================================================================

View File

@ -0,0 +1,17 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_ExternalPackage_ExternalPackage,expat_inc,expat))
$(eval $(call gb_ExternalPackage_add_unpacked_files,expat_inc,inc/external/expat,\
lib/expat.h \
lib/expat_external.h \
))
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,24 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_ExternalProject_ExternalProject,expat))
$(eval $(call gb_ExternalProject_use_unpacked,expat,expat))
$(eval $(call gb_ExternalProject_register_targets,expat,\
configure \
))
$(call gb_ExternalProject_get_state_target,expat,configure) :
cd $(EXTERNAL_WORKDIR) \
&& ./configure \
$(if $(filter YES,$(CROSS_COMPILING)),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
&& touch $@
# vim: set noet sw=4 ts=4:

7
expat/Makefile Normal file
View File

@ -0,0 +1,7 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
module_directory:=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
include $(module_directory)/../solenv/gbuild/partial_build.mk
# vim: set noet sw=4 ts=4:

48
expat/Module_expat.mk Normal file
View File

@ -0,0 +1,48 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_Module_Module,expat))
ifeq ($(SYSTEM_EXPAT),NO)
$(eval $(call gb_Module_add_targets,expat,\
ExternalPackage_expat \
UnpackedTarball_expat \
StaticLibrary_ascii_expat_xmlparse \
StaticLibrary_expat_xmlparse \
StaticLibrary_expat_xmltok \
))
# Actually it wasn't that clear if we should
# run configure step on mingw or not:
# CONFIGURATION_ACTION wasn't set, but
# CROSS_COMPILE case was handled in original makefile
# tested it on mingw and it doesn't hurt ;-)
#ifneq ($(OS),WNT)
ifneq ($(OS)$(COM),WNTMSC)
$(eval $(call gb_Module_add_targets,expat,\
ExternalProject_expat \
))
endif
# ---------------- X64 stuff special ---------------------
# use UNICODE only because shell/shlxthandler
# doesn't link against ascii_expat_xmlparse
#---------------------------------------------------------
ifeq ($(BUILD_X64),TRUE)
$(eval $(call gb_Module_add_targets,expat,\
StaticLibrary_expat_xmlparse_x64 \
StaticLibrary_expat_xmltok_x64 \
))
endif
endif
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,49 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_StaticLibrary_StaticLibrary,ascii_expat_xmlparse))
$(eval $(call gb_StaticLibrary_set_warnings_not_errors,ascii_expat_xmlparse))
$(eval $(call gb_StaticLibrary_use_unpacked,ascii_expat_xmlparse,expat))
# no configure step on windows, no dependency
ifneq ($(OS)$(COM),WNTMSC)
$(eval $(call gb_StaticLibrary_use_external_project,ascii_expat_xmlparse,expat))
endif
$(eval $(call gb_StaticLibrary_set_include,ascii_expat_xmlparse,\
-I$(call gb_UnpackedTarball_get_dir,expat) \
$$(INCLUDE) \
))
ifeq ($(OS),MACOSX)
ifneq ($(strip $(SYSBASE)),)
$(eval $(call gb_StaticLibrary_add_defs,ascii_expat_xmlparse,\
-DHAVE_MEMMOVE \
-DHAVE_BCOPY \
))
endif
endif
ifeq ($(OS),WNT)
$(eval $(call gb_StaticLibrary_add_defs,ascii_expat_xmlparse,\
-DCOMPILED_FROM_DSP \
))
else
$(eval $(call gb_StaticLibrary_add_defs,ascii_expat_xmlparse,\
-DHAVE_EXPAT_CONFIG_H \
))
endif
$(eval $(call gb_StaticLibrary_add_generated_cobjects,ascii_expat_xmlparse,\
UnpackedTarball/expat/lib/xmlparse \
))
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,53 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_StaticLibrary_StaticLibrary,expat_xmlparse))
$(eval $(call gb_StaticLibrary_set_warnings_not_errors,expat_xmlparse))
$(eval $(call gb_StaticLibrary_use_unpacked,expat_xmlparse,expat))
# no configure step on windows, no dependency
ifneq ($(OS)$(COM),WNTMSC)
$(eval $(call gb_StaticLibrary_use_external_project,expat_xmlparse,expat))
endif
$(eval $(call gb_StaticLibrary_add_defs,expat_xmlparse,\
-DXML_UNICODE \
))
$(eval $(call gb_StaticLibrary_set_include,expat_xmlparse,\
-I$(call gb_UnpackedTarball_get_dir,expat) \
$$(INCLUDE) \
))
ifeq ($(OS),MACOSX)
ifneq ($(strip $(SYSBASE)),)
$(eval $(call gb_StaticLibrary_add_defs,expat_xmlparse,\
-DHAVE_MEMMOVE \
-DHAVE_BCOPY \
))
endif
endif
ifeq ($(OS),WNT)
$(eval $(call gb_StaticLibrary_add_defs,expat_xmlparse,\
-DCOMPILED_FROM_DSP \
))
else
$(eval $(call gb_StaticLibrary_add_defs,expat_xmlparse,\
-DHAVE_EXPAT_CONFIG_H \
))
endif
$(eval $(call gb_StaticLibrary_add_generated_cobjects,expat_xmlparse,\
UnpackedTarball/expat/lib/unicode_xmlparse \
))
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,32 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_StaticLibrary_StaticLibrary,expat_xmlparse_x64))
$(eval $(call gb_StaticLibrary_set_x64,expat_xmlparse_x64,YES))
$(eval $(call gb_StaticLibrary_set_warnings_not_errors,expat_xmlparse_x64))
$(eval $(call gb_StaticLibrary_use_unpacked,expat_xmlparse_x64,expat))
$(eval $(call gb_StaticLibrary_set_include,expat_xmlparse_x64,\
-I$(call gb_UnpackedTarball_get_dir,expat) \
$$(INCLUDE) \
))
$(eval $(call gb_StaticLibrary_add_defs,expat_xmlparse_x64,\
-DCOMPILED_FROM_DSP \
-DXML_UNICODE \
))
$(eval $(call gb_StaticLibrary_add_x64_generated_cobjects,expat_xmlparse_x64,\
UnpackedTarball/expat/lib/xmlparse_x64 \
))
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,50 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_StaticLibrary_StaticLibrary,expat_xmltok))
$(eval $(call gb_StaticLibrary_set_warnings_not_errors,expat_xmltok))
$(eval $(call gb_StaticLibrary_use_unpacked,expat_xmltok,expat))
# no configure step on windows, no dependency
ifneq ($(OS)$(COM),WNTMSC)
$(eval $(call gb_StaticLibrary_use_external_project,expat_xmltok,expat))
endif
$(eval $(call gb_StaticLibrary_set_include,expat_xmltok,\
-I$(call gb_UnpackedTarball_get_dir,expat) \
$$(INCLUDE) \
))
ifeq ($(OS),MACOSX)
ifneq ($(strip $(SYSBASE)),)
$(eval $(call gb_StaticLibrary_add_defs,expat_xmltok,\
-DHAVE_MEMMOVE \
-DHAVE_BCOPY \
))
endif
endif
ifeq ($(OS),WNT)
$(eval $(call gb_StaticLibrary_add_defs,expat_xmltok,\
-DCOMPILED_FROM_DSP \
))
else
$(eval $(call gb_StaticLibrary_add_defs,expat_xmltok,\
-DHAVE_EXPAT_CONFIG_H \
))
endif
$(eval $(call gb_StaticLibrary_add_generated_cobjects,expat_xmltok,\
UnpackedTarball/expat/lib/xmltok \
UnpackedTarball/expat/lib/xmlrole \
))
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,33 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_StaticLibrary_StaticLibrary,expat_xmltok_x64))
$(eval $(call gb_StaticLibrary_set_x64,expat_xmltok_x64,YES))
$(eval $(call gb_StaticLibrary_set_warnings_not_errors,expat_xmltok_x64))
$(eval $(call gb_StaticLibrary_use_unpacked,expat_xmltok_x64,expat))
$(eval $(call gb_StaticLibrary_set_include,expat_xmltok_x64,\
-I$(call gb_UnpackedTarball_get_dir,expat) \
$$(INCLUDE) \
))
$(eval $(call gb_StaticLibrary_add_defs,expat_xmltok_x64,\
-DXML_UNICODE \
-DCOMPILED_FROM_DSP \
))
$(eval $(call gb_StaticLibrary_add_x64_generated_cobjects,expat_xmltok_x64,\
UnpackedTarball/expat/lib/xmltok_x64 \
UnpackedTarball/expat/lib/xmlrole_x64 \
))
# vim: set noet sw=4 ts=4:

View File

@ -0,0 +1,33 @@
# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
#
# This file is part of the LibreOffice project.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
$(eval $(call gb_UnpackedTarball_UnpackedTarball,expat))
$(eval $(call gb_UnpackedTarball_set_tarball,expat,$(EXPAT_TARBALL)))
$(eval $(call gb_UnpackedTarball_add_patches,expat,\
expat/expat-2.1.0.patch \
))
# This is a bit hackish
# we need to compile it twice:
# with -DXML_UNICODE and without.
# This is a bit hackish too ;-)
# on windows 64 bit platform we need to link it twice:
# with $(LINK_X64_BINARY) and with $(gb_LINK).
$(eval $(call gb_UnpackedTarball_set_post_action,expat,\
$(GNUCOPY) lib/xmlparse.c lib/unicode_xmlparse.c \
$(if $(filter $(BUILD_X64),TRUE), && \
$(GNUCOPY) lib/xmlparse.c lib/xmlparse_x64.c && \
$(GNUCOPY) lib/xmltok.c lib/xmltok_x64.c && \
$(GNUCOPY) lib/xmlrole.c lib/xmlrole_x64.c)\
))
# vim: set noet sw=4 ts=4:

View File

@ -1,97 +1,3 @@
--- misc/expat-2.1.0/lib/makefile.mk Wed Aug 20 14:33:55 2008
+++ misc/build/expat-2.1.0/lib/makefile.mk Wed Aug 20 14:26:42 2008
@@ -1 +1,90 @@
-dummy
+#*************************************************************************
+#
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# Copyright 2000, 2010 Oracle and/or its affiliates.
+#
+# OpenOffice.org - a multi-platform office productivity suite
+#
+# This file is part of OpenOffice.org.
+#
+# OpenOffice.org is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License version 3
+# only, as published by the Free Software Foundation.
+#
+# OpenOffice.org is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Lesser General Public License version 3 for more details
+# (a copy is included in the LICENSE file that accompanied this code).
+#
+# You should have received a copy of the GNU Lesser General Public License
+# version 3 along with OpenOffice.org. If not, see
+# <http://www.openoffice.org/license.html>
+# for a copy of the LGPLv3 License.
+#
+#*************************************************************************
+PRJ=../../../../..
+
+PRJNAME=expat
+TARGET=expat
+LIBTARGET=NO
+EXTERNAL_WARNINGS_NOT_ERRORS=TRUE
+VISIBILITY_HIDDEN=TRUE
+
+# --- Settings -----------------------------------------------------
+.INCLUDE : settings.mk
+# --- Files --------------------------------------------------------
+
+CFLAGS+=-I..
+
+.IF "$(OS)"=="WNT"
+CDEFS+=-DCOMPILED_FROM_DSP
+.ELSE
+CDEFS+=-DHAVE_EXPAT_CONFIG_H
+.ENDIF
+
+.IF "$(OS)"=="MACOSX" && "$(SYSBASE)"!=""
+CDEFS+=-DHAVE_MEMMOVE -DHAVE_BCOPY
+.ENDIF # "$(OS)"=="MACOSX"
+
+SLOFILES=$(SLO)/xmlparse.obj \
+ $(SLO)/xmlrole.obj \
+ $(SLO)/xmltok.obj
+
+SECOND_BUILD=UNICODE
+UNICODE_SLOFILES=$(SLO)/xmlparse.obj
+UNICODECDEFS+=-DXML_UNICODE
+
+LIB1ARCHIV=$(LB)/libascii_$(TARGET)_xmlparse.a
+LIB1TARGET=$(SLB)/ascii_$(TARGET)_xmlparse.lib
+LIB1OBJFILES=$(SLO)/xmlparse.obj
+
+LIB2ARCHIV=$(LB)/lib$(TARGET)_xmlparse.a
+LIB2TARGET=$(SLB)/$(TARGET)_xmlparse.lib
+LIB2OBJFILES =$(REAL_UNICODE_SLOFILES)
+
+LIB3ARCHIV=$(LB)/lib$(TARGET)_xmltok.a
+LIB3TARGET=$(SLB)/$(TARGET)_xmltok.lib
+LIB3OBJFILES=$(SLO)/xmlrole.obj $(SLO)/xmltok.obj
+
+.IF "$(BUILD_X64)"!=""
+# ---------------- X64 stuff special ---------------------
+# use UNICODE only because shell/shlxthandler
+# doesn't link against ascii_expat_xmlparse
+#---------------------------------------------------------
+SLOFILES_X64=$(SLO_X64)/xmlparse.obj \
+ $(SLO_X64)/xmlrole.obj \
+ $(SLO_X64)/xmltok.obj
+CDEFS_X64+=-DXML_UNICODE -DCOMPILED_FROM_DSP
+CFLAGS_X64+=-I..
+LIB1TARGET_X64=$(SLB_X64)/$(TARGET)_xmlparse.lib
+LIB1OBJFILES_X64=$(SLO_X64)/xmlparse.obj
+LIB2TARGET_X64=$(SLB_X64)/$(TARGET)_xmltok.lib
+LIB2OBJFILES_X64=$(SLO_X64)/xmlrole.obj $(SLO_X64)/xmltok.obj
+.ENDIF # "$(BUILD_X64)"!=""
+
+# --- Targets ------------------------------------------------------
+.INCLUDE : set_wntx64.mk
+.INCLUDE : target.mk
+.INCLUDE : tg_wntx64.mk
--- misc/expat-2.1.0/lib/expat_external.h
+++ misc/build/expat-2.1.0/lib/expat_external.h
@@ -86,9 +86,11 @@
@ -182,3 +88,16 @@
#ifdef __cplusplus
extern "C" {
#endif
--- misc/expat-2.1.0/lib/expat_external.h 2009-11-16 08:53:17.375000000 +0000
+++ misc/build/expat-2.1.0/lib/expat_external.h 2009-11-16 08:53:34.703125000 +0000
@@ -7,10 +7,6 @@
/* External API definitions */
-#if defined(_MSC_EXTENSIONS) && !defined(__BEOS__) && !defined(__CYGWIN__)
-#define XML_USE_MSC_EXTENSIONS 1
-#endif
-
/* Expat tries very hard to make the API boundary very specifically
defined. There are two macros defined to control this boundary;
each of these can be defined before including this header to

View File

@ -1,69 +0,0 @@
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2000, 2010 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
#
# This file is part of OpenOffice.org.
#
# OpenOffice.org is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License version 3
# only, as published by the Free Software Foundation.
#
# OpenOffice.org is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License version 3 for more details
# (a copy is included in the LICENSE file that accompanied this code).
#
# You should have received a copy of the GNU Lesser General Public License
# version 3 along with OpenOffice.org. If not, see
# <http://www.openoffice.org/license.html>
# for a copy of the LGPLv3 License.
#
#*************************************************************************
PRJ=.
PRJNAME=so_expat
TARGET=so_expat
# --- Settings -----------------------------------------------------
.INCLUDE : settings.mk
.IF "$(SYSTEM_EXPAT)" == "YES"
all:
@echo "An already available installation of expat should exist on your system."
@echo "Therefore the version provided here does not need to be built in addition."
.ENDIF
# --- Files --------------------------------------------------------
TARFILE_NAME=expat-2.1.0
TARFILE_MD5=dd7dab7a5fea97d2a6a43f511449b7cd
ADDITIONAL_FILES=lib/makefile.mk
PATCH_FILES=expat-2.1.0.patch \
expat-winapi.patch
CONFIGURE_DIR=
.IF "$(OS)"=="WNT"
CONFIGURE_ACTION=
.ELSE
CONFIGURE_ACTION=./configure
.ENDIF
.IF "$(CROSS_COMPILING)"=="YES"
CONFIGURE_FLAGS+=--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)
.ENDIF
BUILD_DIR=lib
BUILD_ACTION=dmake $(MFLAGS) $(CALLMACROS)
# --- Targets ------------------------------------------------------
.INCLUDE : set_ext.mk
.INCLUDE : target.mk
.INCLUDE : tg_ext.mk

View File

@ -1,3 +1,2 @@
ep expat : soltools NULL
ep expat usr1 - all ep_mkout NULL
ep expat nmake - all ep_expat NULL
ep expat\prj nmake - all ep_expat NULL

View File

@ -1,15 +0,0 @@
mkdir: %_DEST%\inc\external\expat
mkdir: %_DEST%\lib\x64
..\%__SRC%\misc\build\expat-2.1.0\lib\expat.h %_DEST%\inc\external\expat.h
..\%__SRC%\misc\build\expat-2.1.0\lib\expat_external.h %_DEST%\inc\external\expat_external.h
..\%__SRC%\slb\expat_xmltok.lib %_DEST%\lib\expat_xmltok.lib
..\%__SRC%\slb\expat_xmlparse.lib %_DEST%\lib\expat_xmlparse.lib
..\%__SRC%\slb\ascii_expat_xmlparse.lib %_DEST%\lib\ascii_expat_xmlparse.lib
..\%__SRC%\lib\libexpat_xmltok.a %_DEST%\lib\libexpat_xmltok.a
..\%__SRC%\lib\libexpat_xmlparse.a %_DEST%\lib\libexpat_xmlparse.a
..\%__SRC%\lib\libascii_expat_xmlparse.a %_DEST%\lib\libascii_expat_xmlparse.a
..\%__SRC%\misc\_ooo_st_expat_xmltok.pdb %_DEST%\lib\_ooo_st_expat_xmltok.pdb
..\%__SRC%\misc\_ooo_st_expat_xmlparse.pdb %_DEST%\lib\_ooo_st_expat_xmlparse.pdb
..\%__SRC%\slb\x64\expat_xmltok.lib %_DEST%\lib\x64\expat_xmltok.lib
..\%__SRC%\slb\x64\expat_xmlparse.lib %_DEST%\lib\x64\expat_xmlparse.lib

View File

View File

@ -25,7 +25,7 @@ d70951c80dabecc2892c919ff5d07172-db-4.7.25.NC-custom.tar.gz
e0707ff896045731ff99e99799606441-README_db-4.7.25.NC-custom.txt
e81c2f0953aa60f8062c05a4673f2be0-Python-2.6.1.tar.bz2
e61d0364a30146aaa3001296f853b2b9-libxslt-1.1.26.tar.gz
dd7dab7a5fea97d2a6a43f511449b7cd-expat-2.1.0.tar.gz
@EXPAT_TARBALL@
fca8706f2c4619e2fa3f8f42f8fc1e9d-rasqal-0.9.16.tar.gz
0981bda6548a8c8233ffce2b6e4b2a23-mysql-connector-c++-1.1.0.tar.gz
@POSTGRESQL_TARBALL@

View File

@ -54,7 +54,7 @@ $(eval $(call gb_Library_add_defs,ooofilt_x64,\
))
$(eval $(call gb_Library_use_externals,ooofilt_x64,\
expat_utf16 \
expat_utf16_x64 \
zlib \
))

View File

@ -54,7 +54,7 @@ $(eval $(call gb_Library_add_defs,propertyhdl_x64,\
))
$(eval $(call gb_Library_use_externals,propertyhdl_x64,\
expat_utf16 \
expat_utf16_x64 \
zlib \
))

View File

@ -54,7 +54,7 @@ $(eval $(call gb_Library_add_defs,shlxthdl_x64,\
))
$(eval $(call gb_Library_use_externals,shlxthdl_x64,\
expat_utf16 \
expat_utf16_x64 \
zlib \
))

View File

@ -35,7 +35,7 @@ $(eval $(call gb_StaticLibrary_set_include,shell_xmlparser_x64,\
))
$(eval $(call gb_StaticLibrary_use_externals,shell_xmlparser_x64,\
expat_utf16 \
expat_utf16_x64 \
))
$(eval $(call gb_StaticLibrary_add_x64_generated_exception_objects,shell_xmlparser_x64,\

View File

@ -1047,6 +1047,12 @@ define gb_LinkTarget_add_generated_cobjects
$(foreach obj,$(2),$(call gb_LinkTarget_add_generated_c_object,$(1),$(obj),$(3),$(4)))
endef
#only useful for building x64 libraries on windows
define gb_LinkTarget_add_x64_generated_cobjects
$(foreach obj,$(2),$(call gb_LinkTarget_add_generated_c_object,$(1),$(obj),$(3),$(4)))
$(foreach obj,$(2),$(eval $(call gb_GenCObject_get_target,$(obj)) : COBJECT_X64 := YES))
endef
define gb_LinkTarget_add_generated_cxxobjects
$(foreach obj,$(2),$(call gb_LinkTarget_add_generated_cxx_object,$(1),$(obj),$(3)))
endef
@ -1155,6 +1161,14 @@ $(call gb_LinkTarget_get_external_headers_target,$(1)) :| $(call gb_UnpackedTarb
endef
# Use artifacts from ExternalProject (i. e. configure) of an external project
# example in expat: StaticLibrary depends on ExternalProject outcome
define gb_LinkTarget_use_external_project
$(call gb_LinkTarget_get_external_headers_target,$(1)) :| $(call gb_ExternalProject_get_target,$(2))
endef
# this forwards to functions that must be defined in RepositoryExternal.mk.
# $(eval $(call gb_LinkTarget_use_external,library,external))
define gb_LinkTarget_use_external

View File

@ -82,6 +82,7 @@ $(eval $(foreach method,\
add_x64_generated_exception_objects \
add_noexception_objects \
add_generated_cobjects \
add_x64_generated_cobjects \
add_generated_cxxobjects \
add_generated_exception_objects \
add_cflags \
@ -114,6 +115,7 @@ $(eval $(foreach method,\
use_package \
use_packages \
use_unpacked \
use_external_project \
use_static_libraries \
add_sdi_headers \
set_warnings_not_errors \

View File

@ -267,7 +267,7 @@ $(call gb_Output_announce,$(2).c,$(true),C ,3)
$(call gb_Helper_abbreviate_dirs,\
mkdir -p $(dir $(1)) $(dir $(4)) && \
unset INCLUDE && \
$(gb_CC) \
$(if $(filter YES,$(COBJECT_X64)), $(CXX_X64_BINARY), $(gb_CC)) \
$(DEFS) \
$(if $(filter Library,$(TARGETTYPE)),$(gb_COMPILER_LTOFLAGS)) \
$(T_CFLAGS) \
@ -276,6 +276,7 @@ $(call gb_Helper_abbreviate_dirs,\
$(gb_COMPILERDEPFLAGS) \
-I$(dir $(3)) \
$(INCLUDE) \
$(if $(filter YES,$(COBJECT_X64)), -U_X86_ -D_AMD64_,) \
-c $(3) \
-Fo$(1)) $(call gb_create_deps,$(4),$(1),$(3))
endef