diff options
-rw-r--r-- | python/makefile.mk | 7 | ||||
-rw-r--r-- | python/prj/d.lst | 1 | ||||
-rw-r--r-- | python/pyversion.Makefile | 25 | ||||
-rw-r--r-- | scp2/InstallModule_python.mk | 2 |
4 files changed, 33 insertions, 2 deletions
diff --git a/python/makefile.mk b/python/makefile.mk index 3e710954a7fc..1f41a96866a7 100644 --- a/python/makefile.mk +++ b/python/makefile.mk @@ -172,6 +172,7 @@ BUILD_ACTION=$(COMPATH)$/vcpackages$/vcbuild.exe pcbuild.sln "$(CONF)|$(ARCH)" .ENDIF PYVERSIONFILE=$(MISC)$/pyversion.mk +PYVERSIONGFILE=$(MISC)$/pyversion.Makefile # --- Targets ------------------------------------------------------ @@ -207,7 +208,7 @@ $(PYCONFIG) : $(MISC)$/build$/$(TARFILE_NAME)$/PC$/pyconfig.h .ENDIF .ENDIF -ALLTAR : $(PYVERSIONFILE) +ALLTAR : $(PYVERSIONFILE) $(PYVERSIONGFILE) .ENDIF # "$(L10N_framework)"=="" # rule to allow relocating the whole framework, removing reference to buildinstallation directory @@ -252,4 +253,8 @@ $(PYVERSIONFILE) : pyversion.mk $(PACKAGE_DIR)$/$(PREDELIVER_FLAG_FILE) @-rm -f $@ $(COMMAND_ECHO)$(COPY) pyversion.mk $@ +$(PYVERSIONGFILE) : pyversion.Makefile $(PACKAGE_DIR)$/$(PREDELIVER_FLAG_FILE) + @-rm -f $@ + $(COMMAND_ECHO)$(COPY) pyversion.Makefile $@ + .ENDIF # DISABLE_PYTHON != TRUE diff --git a/python/prj/d.lst b/python/prj/d.lst index 4fb4405ebaa7..0c936ab04d48 100644 --- a/python/prj/d.lst +++ b/python/prj/d.lst @@ -8,6 +8,7 @@ mkdir: %_DEST%\lib\OOoPython.framework\Versions\2.6\include\python2.6 # MACOSX - end ..\%__SRC%\misc\pyversion.mk %_DEST%\inc\pyversion.mk +..\%__SRC%\misc\pyversion.Makefile %_DEST%\inc\pyversion.Makefile mkdir: %_DEST%\lib\python mkdir: %_DEST%\lib\python\lib-old diff --git a/python/pyversion.Makefile b/python/pyversion.Makefile new file mode 100644 index 000000000000..4b4be9cb2431 --- /dev/null +++ b/python/pyversion.Makefile @@ -0,0 +1,25 @@ +# when you want to change the python version, you must update the d.lst +# in the python project accordingly !!! +PYMAJOR:=2 +PYMINOR:=6 +PYMICRO:=1 +PYVERSION:=$(PYMAJOR).$(PYMINOR).$(PYMICRO) + +ifeq ($(GUI),UNX) +ifeq ($(OS),MACOSX) +PY_FULL_DLL_NAME:=libpython$(PYMAJOR).$(PYMINOR).a +PYTHONLIB=-F$(SOLARLIBDIR) -framework OOoPython +CFLAGS+=-I$(SOLARLIBDIR)/OOoPython.framework/Versions/$(PYMAJOR).$(PYMINOR)/include/python$(PYMAJOR).$(PYMINOR) +else +PY_FULL_DLL_NAME:=libpython$(PYMAJOR).$(PYMINOR).so.1.0 +PYTHONLIB:=-lpython$(PYMAJOR).$(PYMINOR) +endif +else +ifeq ($(COM),GCC) +PY_FULL_DLL_NAME:=libpython$(PYMAJOR).$(PYMINOR).dll +PYTHONLIB:=-lpython$(PYMAJOR).$(PYMINOR) +else +PY_FULL_DLL_NAME:=python$(PYMAJOR)$(PYMINOR).dll +PYTHONLIB:=python$(PYMAJOR)$(PYMINOR).lib +endif +endif diff --git a/scp2/InstallModule_python.mk b/scp2/InstallModule_python.mk index 774775de1c0b..53d08911fba9 100644 --- a/scp2/InstallModule_python.mk +++ b/scp2/InstallModule_python.mk @@ -41,7 +41,7 @@ $(eval $(call gb_InstallModule_add_defs,scp2/python,\ -DSYSTEM_PYTHON \ )) else -include $(OUTDIR)/inc/pyversion.mk +include $(OUTDIR)/inc/pyversion.Makefile $(eval $(call gb_InstallModule_add_defs,scp2/python,\ -DPYVERSION=$(PYVERSION) \ |