diff options
author | David Ostrovsky <d.ostrovsky@gmx.de> | 2012-06-18 00:04:19 +0200 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2012-06-22 13:11:41 +0200 |
commit | d712218cc0b658fae66f63c52af7996b714289c9 (patch) | |
tree | 74ebe377301f044f5ebd13d7e0ef645817c24dc0 /pyuno/CustomTarget_zipcore.mk | |
parent | 3f5245db4b0248bb55c37d3400b8155263880f6e (diff) |
fixing pyuno bridge on mingw: packaging system-python
Change-Id: Ib46248d217b0161dc20dde0274842bd7381f0cda
Diffstat (limited to 'pyuno/CustomTarget_zipcore.mk')
-rw-r--r-- | pyuno/CustomTarget_zipcore.mk | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/pyuno/CustomTarget_zipcore.mk b/pyuno/CustomTarget_zipcore.mk index ba220845b6f5..98e3c292fc2f 100644 --- a/pyuno/CustomTarget_zipcore.mk +++ b/pyuno/CustomTarget_zipcore.mk @@ -26,7 +26,18 @@ $(eval $(call gb_CustomTarget_CustomTarget,pyuno/zipcore)) +# system python (only mingw) +ifeq ($(SYSTEM_PYTHON),YES) +# mingw: MINGW_PYVERSION and MINGW_SYSROOT are defined in configure +ifeq ($(GUI)$(COM),WNTGCC) +PYVERSION=$(MINGW_PYVERSION) +pyuno_PYTHON_LIB_DIR=$(MINGW_SYSROOT)/lib/python$(MINGW_PYTHON_MAJOR_VERSION) +endif +else include $(OUTDIR)/inc/pyversion.Makefile +pyuno_PYTHON_LIB_DIR=$(OUTDIR)/lib/python +endif + pyuno_PYTHON_ARCHIVE_NAME:=python-core-$(PYVERSION).zip FIND=find GREP=grep @@ -36,12 +47,12 @@ $(call gb_CustomTarget_get_target,pyuno/zipcore) : \ # capture the files to have them in prerequisite list pyuno_zipcore_FINDLIBFILES:=\ - $(shell $(FIND) $(OUTDIR)/lib/python -type f| $(GREP) -v "\.pyc" | $(GREP) -v "\.py~" | $(GREP) -v .orig | $(GREP) -v _failed) + $(shell $(FIND) $(pyuno_PYTHON_LIB_DIR) -type f| $(GREP) -v "\.pyc" | $(GREP) -v "\.py~" | $(GREP) -v .orig | $(GREP) -v _failed) # create zip archive $(call gb_CustomTarget_get_workdir,pyuno/zipcore)/$(pyuno_PYTHON_ARCHIVE_NAME) : $(pyuno_zipcore_FINDLIBFILES) | \ $(call gb_CustomTarget_get_workdir,pyuno/zipcore)/.dir $(call gb_Output_announce,$(subst $(WORKDIR)/,,$@),$(true),ZIP,1) - cd $(OUTDIR)/lib/python && zip $@ $(shell cd $(OUTDIR)/lib/python && $(FIND) . -type f | $(GREP) -v "\.pyc" | $(GREP) -v "\.py~" | $(GREP) -v .orig | $(GREP) -v _failed) + cd $(pyuno_PYTHON_LIB_DIR) && zip $@ $(shell cd $(pyuno_PYTHON_LIB_DIR) && $(FIND) . -type f | $(GREP) -v "\.pyc" | $(GREP) -v "\.py~" | $(GREP) -v .orig | $(GREP) -v _failed) # vim: set noet sw=4 ts=4: |