forked from amazingfate/loongoffice
The module builds here on Fedora 17 and with MSVC2008.
MacOS X is unfinished and probably breaks, which is why the module
is disabled now.
These patches from module python were dropped:
Integrated upstream:
- Python.mipsel-py4305.patch
- Python-2.6.1-py4768.patch
- Python-2.6.1-py2422.patch (modified, use --with-valgrind)
- Python-2.6.1-urllib.patch
- Python-2.6.1-py8067.patch
Obsolete:
- Python-2.6.1-svn-1.7.patch (migrated to non-toy HG now)
- Python-parallel-make.patch
- Python-2.6.1-nohardlink.patch (no idea why that would be needed,
NFS should support hard links)
- Python-2.6.1-sysbase.patch (Solaris 11 setsolar specific patch)
- Python-2.6.1-cross.berkeleydb.patch (berekeleydb removal)
- Python-2.6.2-bdb48.patch
- Python-2.6.1-vc10.patch (upstream supports vc10)
An attempt to cross compile with mingw that proved unsucessful according
to dtardon; there is upstream work on this topic that is possibly
already in 3.3: http://bugs.python.org/issue8067
- Python-2.6.2-cross.patch
- Python-2.6.2-cross.fix-configure.patch
Change-Id: Iba9a3cab955983e173e12110f93a6f381d86f9ce
86 lines
3.4 KiB
Makefile
86 lines
3.4 KiB
Makefile
# -*- 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,python3))
|
|
|
|
$(eval $(call gb_ExternalProject_use_unpacked,python3,python3))
|
|
|
|
$(eval $(call gb_ExternalProject_use_external,python3,expat))
|
|
|
|
$(eval $(call gb_ExternalProject_register_targets,python3,\
|
|
build \
|
|
))
|
|
|
|
ifeq ($(OS)$(COM),WNTMSC)
|
|
|
|
# TODO: using Debug configuration and related mangling of pyconfig.h
|
|
|
|
# at least for MSVC 2008 it is necessary to clear MAKEFLAGS because
|
|
# nmake is invoked
|
|
$(call gb_ExternalProject_get_state_target,python3,build) :
|
|
ifeq ($(VCVER),110)
|
|
cd $(EXTERNAL_WORKDIR)/PCbuild \
|
|
&& MAKEFLAGS= MSBuild.exe pcbuild.sln /t:Build /p:Configuration=Release /p:PlatformToolset=v110 \
|
|
cd $(EXTERNAL_WORKDIR) \
|
|
&& ln -s $(if $(filter 90,$(VCVER)),PC/VS9.0,PCbuild) LO_lib \
|
|
&& touch $@
|
|
else ifeq ($(VCVER),100)
|
|
cd $(EXTERNAL_WORKDIR)/PCbuild \
|
|
&& MAKEFLAGS= MSBuild.exe pcbuild.sln /t:Build /p:Configuration=Release /ToolsVersion:4.0 \
|
|
cd $(EXTERNAL_WORKDIR) \
|
|
&& ln -s $(if $(filter 90,$(VCVER)),PC/VS9.0,PCbuild) LO_lib \
|
|
&& touch $@
|
|
else ifeq ($(VCVER),90)
|
|
cd $(EXTERNAL_WORKDIR)/PC/VS9.0 \
|
|
&& MAKEFLAGS= $(COMPATH)/vcpackages/vcbuild.exe pcbuild.sln "Release|$(if $(filter INTEL,$(CPUNAME)),Win32,x64)" \
|
|
cd $(EXTERNAL_WORKDIR) \
|
|
&& ln -s $(if $(filter 90,$(VCVER)),PC/VS9.0,PCbuild) LO_lib \
|
|
&& touch $@
|
|
endif
|
|
|
|
else
|
|
|
|
# this was added in 2004, hopefully is obsolete now (and why only intel anyway)? $(if $(filter SOLARIS-INTEL,$(OS)$(CPUNAME)),--disable-ipv6)
|
|
|
|
# --with-system-expat: this should find the one in the solver (or system)
|
|
|
|
# create a symlink "LO_lib" because the .so are in a directory with platform
|
|
# specific name like build/lib.linux-x86_64-3.3
|
|
|
|
$(call gb_ExternalProject_get_state_target,python3,build) :
|
|
cd $(EXTERNAL_WORKDIR) \
|
|
&& ./configure \
|
|
$(if $(filter YES,$(CROSS_COMPILING)),--build=$(BUILD_PLATFORM) --host=$(HOST_PLATFORM)) \
|
|
--enable-shared \
|
|
--with-system-expat \
|
|
$(if $(strip $(VALGRIND_CFLAGS)),--with-valgrind) \
|
|
--prefix=/$(if $(filter MACOSX,$(OS)),@__________________________________________________OOO,python-inst) \
|
|
$(if $(filter AIX,$(OS)),--disable-ipv6 --with-threads CFLAGS="-g0") \
|
|
$(if $(filter WNT-GCC,$(OS)-$(COM)),--with-threads ac_cv_printf_zd_format=no) \
|
|
$(if $(filter MACOSX,$(OS)),--enable-universalsdk=$(MACOSX_SDK_PATH) --with-universal-archs=32-bit --enable-frameworks=/SomeDirThatIsNotLibraryOrSystemOrFrameworks --with-framework-name=OOoPython) \
|
|
CC="$(strip $(CC) \
|
|
$(if $(filter YES,$(SYSTEM_OPENSSL)),, -I$(OUTDIR)/inc/external) \
|
|
$(if $(filter YES,$(SYSTEM_EXPAT)),, -I$(OUTDIR)/inc/external/expat) \
|
|
$(if $(SYSBASE), -I$(SYSBASE)/usr/include) \
|
|
)" \
|
|
LDFLAGS="$(strip $(LDFLAGS) \
|
|
$(if $(filter YES,$(SYSTEM_OPENSSL)),, -L$(OUTDIR)/lib) \
|
|
$(if $(filter YES,$(SYSTEM_EXPAT)),, -L$(OUTDIR)/lib) \
|
|
$(if $(SYSBASE), -L$(SYSBASE)/usr/lib) \
|
|
$(if $(filter WNT-GCC,$(OS)-$(COM)), -shared-libgcc \
|
|
$(if $(filter YES,$(MINGW_SHARED_GCCLIB)),-Wl$(COMMA)--enable-runtime-pseudo-reloc-v2 -Wl$(COMMA)--export-all-symbols)) \
|
|
)" \
|
|
&& MAKEFLAGS=$(if $(VERBOSE)$(verbose),,s) $(MAKE) \
|
|
&& ln -s build/lib.* LO_lib \
|
|
&& touch $@
|
|
|
|
endif
|
|
|
|
# vim: set noet sw=4 ts=4:
|