Kaydet (Commit) ffcaa765 authored tarafından Peter Foley's avatar Peter Foley

convert postgresql to gbuild

Change-Id: Ia1345904a819d8edfad53c8882be35b398e8bc6e
üst b339e4e2
......@@ -122,6 +122,7 @@ oox\
package\
packimages\
padmin\
postgresql\
psprint_config\
pyuno\
qadevOOo\
......@@ -241,7 +242,6 @@ odk\
openldap\
openssl\
pango\
postgresql\
postprocess\
python\
redland\
......
......@@ -112,6 +112,7 @@ $(eval $(call gb_Module_add_moduledirs,tail_end,\
oox \
package \
padmin \
$(call gb_Helper_optional,POSTGRESQL,postgresql) \
psprint_config \
$(call gb_Helper_optional,PYUNO,pyuno) \
$(call gb_Helper_optional,QADEVOOO,qadevOOo) \
......
......@@ -121,6 +121,7 @@ $(eval $(call gb_Module_add_moduledirs,ooo,\
package \
packimages \
padmin \
$(call gb_Helper_optional,POSTGRESQL,postgresql) \
psprint_config \
$(call gb_Helper_optional,PYUNO,pyuno) \
$(if $(strip $(OOO_JUNIT_JAR)),\
......
......@@ -463,6 +463,7 @@ export POPPLER_CFLAGS=@POPPLER_CFLAGS@
export POPPLER_LIBS=@POPPLER_LIBS@
export POSTGRESQL_INC=@POSTGRESQL_INC@
export POSTGRESQL_LIB=@POSTGRESQL_LIB@
export POSTGRESQL_TARBALL=@POSTGRESQL_TARBALL@
export PREBUILD_MOZAB=@PREBUILD_MOZAB@
export PREFIXDIR=@PREFIXDIR@
export PRODUCT=@PRODUCT@
......
......@@ -7780,6 +7780,7 @@ if test "x$enable_postgresql_sdbc" != "xno"; then
POSTGRESQL_LIB=""
POSTGRESQL_INC="%OVERRIDE_ME%"
BUILD_TYPE="$BUILD_TYPE POSTGRESQL"
POSTGRESQL_TARBALL="061a9f17323117c9358ed60f33ecff78-postgresql-9.1.1.tar.bz2"
fi
fi
if test "${SYSTEM_POSTGRESQL}" = "YES"; then
......@@ -7804,6 +7805,7 @@ AC_SUBST(BUILD_POSTGRESQL_SDBC)
AC_SUBST(SYSTEM_POSTGRESQL)
AC_SUBST(POSTGRESQL_INC)
AC_SUBST(POSTGRESQL_LIB)
AC_SUBST(POSTGRESQL_TARBALL)
dnl ===================================================================
......
......@@ -64,7 +64,11 @@ $(eval $(call gb_Library_use_externals,postgresql-sdbc-impl,\
ifneq ($(SYSTEM_POSTGRESQL),YES)
ifneq ($(GUI)$(COM),WNTMSC)
include $(OUTDIR)/inc/postgresql/libpq-flags.mk
$(eval $(call gb_Library_use_external_package,postgresql-sdbc-impl,\
postgresql \
))
-include $(OUTDIR)/inc/postgresql/libpq-flags.mk
$(eval $(call gb_Library_add_libs,postgresql-sdbc-impl,\
$(if $(filter-out MACOSX,$(OS)),-Wl$(COMMA)--as-needed) \
......
......@@ -33,7 +33,7 @@ dd7dab7a5fea97d2a6a43f511449b7cd-expat-2.1.0.tar.gz
fb7ba5c2182be4e73748859967455455-README_stax-api-1.0-2-sources.txt
fca8706f2c4619e2fa3f8f42f8fc1e9d-rasqal-0.9.16.tar.gz
0981bda6548a8c8233ffce2b6e4b2a23-mysql-connector-c++-1.1.0.tar.gz
061a9f17323117c9358ed60f33ecff78-postgresql-9.1.1.tar.bz2
@POSTGRESQL_TARBALL@
46e92b68e31e858512b680b3b61dc4c1-mythes-1.2.3.tar.gz
3dd55b952826d2b32f51308f2f91aa89-gettext-0.18.1.1.tar.gz
9f6e85e1e38490c3956f4415bcd33e6e-glib-2.28.1.tar.gz
......
# -*- 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,postgresql,postgresql))
$(eval $(call gb_ExternalPackage_use_external_project,postgresql,postgresql))
$(eval $(call gb_ExternalPackage_add_unpacked_files,postgresql,inc/postgresql,\
src/include/postgres_ext.h \
src/interfaces/libpq/libpq-fe.h \
))
$(eval $(call gb_ExternalPackage_add_files,postgresql,inc/postgresql,\
src/interfaces/libpq/libpq-flags.mk \
))
ifeq ($(OS),WNT)
$(eval $(call gb_ExternalPackage_add_files,postgresql,lib,\
src/interfaces/libpq/libpq.lib \
))
else
$(eval $(call gb_ExternalPackage_add_files,postgresql,lib,\
src/interfaces/libpq/libpq.a \
))
endif
# vim: set noet sw=4 ts=4:
# -*- 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,postgresql))
$(eval $(call gb_ExternalProject_use_unpacked,postgresql,postgresql))
$(eval $(call gb_ExternalProject_register_targets,postgresql,\
build \
))
ifeq ($(OS)$(COM),WNTMSC)
$(call gb_ExternalProject_get_state_target,postgresql,build) :
cd $(EXTERNAL_WORKDIR)/src \
&& nmake -f win32.mk USE_SSL=1 USE_LDAP=1 USE_MICROSOFT_LDAP=1 \
&& touch $@
else
$(call gb_ExternalProject_get_state_target,postgresql,build) :
cd $(EXTERNAL_WORKDIR) \
&& ./configure \
--without-readline --disable-shared --with-openssl --with-ldap \
$(if $(filter YES,$(CROSS_COMPILING)),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
$(if $(filter YES,$(WITH_KRB5)),--with-krb5) \
$(if $(filter YES,$(WITH_GSSAPI)),--with-gssapi) \
$(if $(filter NO,$(SYSTEM_OPENLDAP)),CPPFLAGS="-I$(OUTDIR)/inc/openldap" LDFLAGS="-L$(OUTDIR)/lib" EXTRA_LDAP_LIBS="-llber -lssl3 -lsmime3 -lnss3 -lnssutil3 -lplds4 -lplc4 -lnspr4") \
&& cd src/interfaces/libpq \
&& unset MAKEFLAGS \
&& $(GNUMAKE) -j$(EXTMAXPROCESS) all-static-lib libpq-flags.mk \
&& touch $@
endif
# vim: set noet sw=4 ts=4:
# -*- 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:
# -*- 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,postgresql))
ifeq ($(SYSTEM_POSTGRESQL),NO)
$(eval $(call gb_Module_add_targets,postgresql,\
ExternalProject_postgresql \
ExternalPackage_postgresql \
UnpackedTarball_postgresql \
))
endif
# vim: set noet sw=4 ts=4:
# -*- 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,postgresql))
$(eval $(call gb_UnpackedTarball_set_tarball,postgresql,$(POSTGRESQL_TARBALL)))
$(eval $(call gb_UnpackedTarball_set_patchlevel,postgresql,3))
$(eval $(call gb_UnpackedTarball_add_patches,postgresql, \
postgresql/postgresql-moz-ldap.patch \
postgresql/postgresql-libs-leak.patch \
postgresql/libpq-parallel-build.patch \
postgresql/postgresql-9.1.1-autoreconf.patch \
postgresql/postgresql-9.1.1-libreoffice.patch \
))
# vim: set noet sw=4 ts=4:
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# Copyright 2008 by Sun Microsystems, Inc.
#
# 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=postgresql
TARGET=so_postgresql
# --- Settings -----------------------------------------------------
.INCLUDE : settings.mk
# --- Files --------------------------------------------------------
TARFILE_NAME=postgresql-9.1.1
TARFILE_MD5=061a9f17323117c9358ed60f33ecff78
PATCH_FILES=\
postgresql-moz-ldap.patch \
postgresql-libs-leak.patch \
libpq-parallel-build.patch \
$(TARFILE_NAME)-libreoffice.patch \
$(TARFILE_NAME)-autoreconf.patch
.IF "$(SYSTEM_POSTGRESQL)" == "YES"
@all:
@echo "Using system postgresql..."
.ENDIF
.IF "$(GUI)$(COM)"=="WNTMSC"
CONFIGURE_DIR=.
BUILD_DIR=src
CONFIGURE_ACTION =
BUILD_ACTION = nmake -f win32.mak USE_SSL=1 USE_LDAP=1 USE_MICROSOFT_LDAP=1
.ELSE #"$(GUI)$(COM)"!="WNTMSC"
CONFIGURE_DIR=.
BUILD_DIR=src/interfaces/libpq
CONFIGURE_ACTION = ./configure --without-readline --disable-shared --with-openssl --with-ldap
.IF "$(OS)" != "WNT" && "$(SYSTEM_OPENLDAP) != "YES"
CONFIGURE_ACTION += CPPFLAGS="-I $(SOLARVER)$/$(INPATH)$/inc$/openldap"
CONFIGURE_ACTION += LDFLAGS="$(SOLARLIB)"
CONFIGURE_ACTION += EXTRA_LDAP_LIBS="-llber -lssl3 -lsmime3 -lnss3 -lnssutil3 -lplds4 -lplc4 -lnspr4"
.ENDIF
.IF "$(CROSS_COMPILING)" == "YES"
CONFIGURE_ACTION += --build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)
.ENDIF
.IF "$(WITH_KRB5)" == "YES"
CONFIGURE_ACTION += --with-krb5
.ENDIF
.IF "$(WITH_GSSAPI)" == "YES"
CONFIGURE_ACTION += --with-gssapi
.ENDIF
BUILD_ACTION = make -j$(GMAKE_MODULE_PARALLELISM) all-static-lib libpq-flags.mk
.ENDIF # "$(GUI)$(COM)"=="WNTMSC"
# --- Targets ------------------------------------------------------
.INCLUDE : set_ext.mk
.INCLUDE : target.mk
.INCLUDE : tg_ext.mk
mkdir: %_DEST%\inc\postgresql
..\%__SRC%\misc\build\postgresql-*\src\include\postgres_ext.h %_DEST%\inc\postgresql
..\%__SRC%\misc\build\postgresql-*\src\interfaces\libpq\libpq-fe.h %_DEST%\inc\postgresql
..\%__SRC%\misc\build\postgresql-*\src\interfaces\libpq\libpq-flags.mk %_DEST%\inc\postgresql
..\%__SRC%\misc\build\postgresql-*\src\interfaces\libpq\libpq.a %_DEST%\lib
..\%__SRC%\misc\build\postgresql-*\src\interfaces\libpq\libpq.lib %_DEST%\lib
......@@ -210,6 +210,8 @@ $(eval $(foreach method,\
add_external_headers \
use_package \
use_packages \
use_external_package \
use_external_packages \
use_unpacked \
add_package_headers \
add_sdi_headers \
......
......@@ -1139,6 +1139,17 @@ define gb_LinkTarget_use_packages
$(foreach package,$(2),$(call gb_LinkTarget_use_package,$(1),$(package)))
endef
# use a external package, possibly from another module (i.e. via OUTDIR)
define gb_LinkTarget_use_external_package
$(call gb_LinkTarget_get_external_headers_target,$(1)) :| \
$(call gb_ExternalPackage_get_target,$(strip $(2)))
endef
define gb_LinkTarget_use_external_packages
$(foreach package,$(2),$(call gb_LinkTarget_use_external_package,$(1),$(package)))
endef
# Use sources from unpacked tarball of an external project
define gb_LinkTarget_use_unpacked
$(call gb_LinkTarget_get_external_headers_target,$(1)) :| $(call gb_UnpackedTarball_get_final_target,$(2))
......
tb tail_build : BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CPPUNIT:cppunit CURL:curl EXPAT:expat FONTCONFIG:fontconfig FREETYPE:freetype GETTEXT:gettext GLIB:glib GDK_PIXBUF:gdk-pixbuf PANGO:pango LIBCROCO:libcroco LIBGSF:libgsf GRAPHITE:graphite HUNSPELL:hunspell HYPHEN:hyphen ICU:icu JPEG:jpeg LCMS2:lcms2 LIBEXTTEXTCAT:libexttextcat LIBLANGTAG:liblangtag LIBXML2:libxml2 libxmlsec LIBXSLT:libxslt LPSOLVE:lpsolve MOZ:moz MYTHES:mythes NSS:nss OPENLDAP:openldap OPENSSL:openssl POSTGRESQL:postgresql PYTHON:python REDLAND:redland stax XPDF:xpdf ZLIB:zlib external sal solenv soltools NULL
tb tail_build : BERKELEYDB:berkeleydb BOOST:boost CAIRO:cairo CPPUNIT:cppunit CURL:curl EXPAT:expat FONTCONFIG:fontconfig FREETYPE:freetype GETTEXT:gettext GLIB:glib GDK_PIXBUF:gdk-pixbuf PANGO:pango LIBCROCO:libcroco LIBGSF:libgsf GRAPHITE:graphite HUNSPELL:hunspell HYPHEN:hyphen ICU:icu JPEG:jpeg LCMS2:lcms2 LIBEXTTEXTCAT:libexttextcat LIBLANGTAG:liblangtag LIBXML2:libxml2 libxmlsec LIBXSLT:libxslt LPSOLVE:lpsolve MOZ:moz MYTHES:mythes NSS:nss OPENLDAP:openldap OPENSSL:openssl PYTHON:python REDLAND:redland stax XPDF:xpdf ZLIB:zlib external sal solenv soltools NULL
tb tail_build\prj nmake - all tb_prj NULL
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment