aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorspiff <spiff@xbmc.org>2011-02-24 20:47:53 +0100
committerJim Carroll <thecarrolls@jiminger.com>2011-04-05 17:11:27 -0400
commitb768137069e3b0db7710c31b45222bfca1a0641b (patch)
treeaaac6198db5ebeeb823ab8d4ce409dd002f34a5d
parent3b508b2349e83103dfe8536eabc3800e39e1508c (diff)
Code changes for external python. Changes include submissions by cptspiff,WiSo,blinkseb, and jcarroll
changed: limit the scope of the python includes. this will be useful in an upcomming patch. credit jcarroll changed: use a m4 check to set the python path directly, and ditch the old hardcoded version nonsense. credit jcarroll Fixed the build for when --enable-external-python is not used. Fixed the warnings due to Python.h not being the first header as required by Python. Final fix to the osx make build so that external python works. Needed to change the m4 macro to account for .dylib on osx and the dependant ./configure call to pass the installed location of the python xbmc is to be built against. Also updated .gitignore for the osx dependency builds. There was a name collision between the python datetime.h and the xbmc/DateTime.h on file systems that are not case sensitive. This is now fixed by renaming DateTime.h to XBDateTime.h By request, the .cpp files now sorted alphabetically in the Makefile.in. the m4 macros is a mess of mixed spaces and tabs. In order to make my couple line change more readable I changed the spaces to tabs so it would be consistent with the surrounding area. This was per the request of jmarshall. Fixed an error where under internal python the correct header wasn't being used. if --enable-external-python is selected then don't build the internal python at all and not using any of the wrappers. Modified the xcode project to work with the external python changes. There was a bug in the Makefile.in where the internal python build target wasn't being set correctly. This is now fixed. [WIN32] removed some uneeded files, renamed DateTime* to XBDateTime* and defined USE_EXTERNAL_PYTHON Added xbmc/cores/DllLoader/Makefile to .gitignore since it's being autogened. Made it so that the distinction between internal and external python is limited to mostly just Makefile's now. Most of the code no longer needs to make the distinction. This should make it much easier to move forward in windows and eventually with removing the internal python. updated: .gitignore
-rw-r--r--.gitignore13
-rw-r--r--Makefile.in23
-rw-r--r--XBMC.xcodeproj/project.pbxproj102
-rw-r--r--configure.in42
-rw-r--r--m4/ax_python_devel.m4333
-rw-r--r--project/VS2010Express/XBMC.vcxproj9
-rw-r--r--project/VS2010Express/XBMC.vcxproj.filters23
-rw-r--r--tools/osx/osx-depends/xbmc/Makefile3
-rw-r--r--xbmc/FileItem.h2
-rw-r--r--xbmc/GUIInfoManager.h2
-rw-r--r--xbmc/Makefile.in2
-rw-r--r--xbmc/TextureDatabase.cpp2
-rw-r--r--xbmc/XBDateTime.cpp (renamed from xbmc/DateTime.cpp)2
-rw-r--r--xbmc/XBDateTime.h (renamed from xbmc/DateTime.h)0
-rw-r--r--xbmc/addons/AddonDatabase.cpp2
-rw-r--r--xbmc/addons/Repository.h2
-rw-r--r--xbmc/addons/Scraper.h2
-rw-r--r--xbmc/dialogs/GUIDialogSeekBar.h2
-rw-r--r--xbmc/filesystem/MythDirectory.h2
-rw-r--r--xbmc/filesystem/MythFile.cpp2
-rw-r--r--xbmc/filesystem/MythFile.h2
-rw-r--r--xbmc/filesystem/MythSession.cpp2
-rw-r--r--xbmc/guilib/GUIEditControl.cpp2
-rw-r--r--xbmc/interfaces/python/Makefile9
-rw-r--r--xbmc/interfaces/python/Makefile.in14
-rw-r--r--xbmc/interfaces/python/XBPyThread.cpp30
-rw-r--r--xbmc/interfaces/python/XBPyThread.h20
-rw-r--r--xbmc/interfaces/python/XBPython.cpp25
-rw-r--r--xbmc/interfaces/python/XBPython.h4
-rw-r--r--xbmc/interfaces/python/XBPythonDll.cpp14
-rw-r--r--xbmc/interfaces/python/XBPythonDll.h3
-rw-r--r--xbmc/interfaces/python/XBPythonDllFuncs.S10
-rw-r--r--xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.cpp33
-rw-r--r--xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.h28
-rw-r--r--xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.cpp20
-rw-r--r--xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.h6
-rw-r--r--xbmc/interfaces/python/xbmcmodule/Makefile.in (renamed from xbmc/interfaces/python/xbmcmodule/Makefile)4
-rw-r--r--xbmc/interfaces/python/xbmcmodule/PythonAddon.h17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/PythonPlayer.h17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/action.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/control.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlbutton.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlcheckmark.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlfadelabel.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlgroup.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlimage.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controllabel.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controllist.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlprogress.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlradiobutton.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlslider.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controlspin.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/controltextbox.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/dialog.cpp17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/dialog.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/infotagmusic.h17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/infotagvideo.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/keyboard.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/listitem.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/listitem.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/player.cpp2
-rw-r--r--xbmc/interfaces/python/xbmcmodule/player.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/pyplaylist.cpp18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/pyplaylist.h17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/pyutil.h19
-rw-r--r--xbmc/interfaces/python/xbmcmodule/window.h18
-rw-r--r--xbmc/interfaces/python/xbmcmodule/winxml.cpp16
-rw-r--r--xbmc/interfaces/python/xbmcmodule/winxml.h17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/winxmldialog.cpp19
-rw-r--r--xbmc/interfaces/python/xbmcmodule/xbmcaddonmodule.cpp17
-rw-r--r--xbmc/interfaces/python/xbmcmodule/xbmcguimodule.cpp23
-rw-r--r--xbmc/interfaces/python/xbmcmodule/xbmcmodule.cpp16
-rw-r--r--xbmc/interfaces/python/xbmcmodule/xbmcplugin.cpp6
-rw-r--r--xbmc/interfaces/python/xbmcmodule/xbmcvfsmodule.cpp16
-rw-r--r--xbmc/network/WebServer.cpp2
-rw-r--r--xbmc/pictures/PictureInfoTag.cpp2
-rw-r--r--xbmc/playlists/SmartPlayList.cpp2
-rw-r--r--xbmc/utils/StringUtils.h2
-rw-r--r--xbmc/utils/TimeUtils.cpp2
-rw-r--r--xbmc/utils/Weather.cpp2
-rw-r--r--xbmc/video/VideoInfoDownloader.h2
-rw-r--r--xbmc/video/VideoInfoScanner.h2
-rw-r--r--xbmc/video/windows/GUIWindowFullScreen.cpp2
-rw-r--r--xbmc/win32/XBMC_PC.cpp2
84 files changed, 613 insertions, 835 deletions
diff --git a/.gitignore b/.gitignore
index 12e1f48fc8..0f7cb7a824 100644
--- a/.gitignore
+++ b/.gitignore
@@ -385,15 +385,7 @@ lib/cmyth/Makefile
/system/profiles.xml
# /system/python
-/system/python/Lib/
-/system/python/python24.zip
-/system/python/python24.dll
-/system/python/DLLs/_socket.pyd
-/system/python/DLLs/pyexpat.pyd
-/system/python/DLLs/select.pyd
-/system/python/DLLs/unicodedata.pyd
-/system/python/DLLs/zlib.pyd
-/system/python/DLLs/bz2.pyd
+/system/python/
# /system/webserver
/system/webserver
@@ -496,6 +488,7 @@ lib/cmyth/Makefile
/xbmc/cores/DllLoader/exports/build_wrapper.sh
/xbmc/cores/DllLoader/exports/wrapper.def
/xbmc/cores/DllLoader/Makefile
+
/xbmc/cores/Makefile
/xbmc/cores/VideoRenderers/Makefile
@@ -1029,6 +1022,8 @@ lib/cmyth/Makefile
# /xbmc/interfaces/
/xbmc/interfaces/Makefile
+/xbmc/interfaces/python/Makefile
+/xbmc/interfaces/python/xbmcmodule/Makefile
/xbmc/interfaces/python/linux/Makefile
/xbmc/interfaces/python/linux/wrapper_python.def
diff --git a/Makefile.in b/Makefile.in
index 5efe6cbed7..21d2288705 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -120,11 +120,14 @@ LIB_DIRS=\
lib/libhdhomerun \
lib/libid3tag \
lib/libapetag \
- xbmc/interfaces/python/linux \
lib/cpluff \
lib/xbmc-dll-symbols \
lib/jsoncpp/src/lib_json
+ifneq (@USE_EXTERNAL_PYTHON@,1)
+LIB_DIRS+=xbmc/interfaces/python/linux
+endif
+
SS_DIRS=\
xbmc/screensavers/rsxs-0.9/xbmc
@@ -168,6 +171,12 @@ DISTCLEAN_FILES=config.h config.log config.status tools/Linux/xbmc.sh \
lib/python/libpython2.4.so.1.0 \
system/libcpluff-@ARCH@.so
+ifneq (@USE_EXTERNAL_PYTHON@,1)
+ PYTHON_TARGET=python
+else
+ PYTHON_TARGET=
+endif
+
all : Makefile externals xbmc.bin xbmc-xrandr skins
include Makefile.include
@@ -407,8 +416,10 @@ endif
libpython: dllloader
$(MAKE) -C xbmc/interfaces/python
$(MAKE) -C xbmc/interfaces/python/xbmcmodule
+ifneq (@USE_EXTERNAL_PYTHON@,1)
python: dllloader
$(MAKE) -C xbmc/interfaces/python/linux
+endif
dvdpcodecs: dllloader
$(MAKE) -C lib
$(MAKE) -C lib/libdvd
@@ -453,6 +464,12 @@ codecs: papcodecs dvdpcodecs
libs: cmyth libhdhomerun libid3tag imagelib libexif python system/libcpluff-@ARCH@.so
externals: codecs libs python visualizations screensavers
+ifeq ($(findstring osx,@ARCH@), osx)
+libs: libhdhomerun libid3tag imagelib libexif $(PYTHON_TARGET) system/libcpluff-@ARCH@.so system/players/paplayer/libmodplug-@ARCH@.so
+else
+libs: libhdhomerun libid3tag imagelib libexif $(PYTHON_TARGET) system/libcpluff-@ARCH@.so
+endif
+
xcode_depends: \
codecs libs python visualizations screensavers eventclients skins \
lib/libsquish/libsquish.a \
@@ -579,6 +596,10 @@ ifeq ($(findstring arm,@ARCH@), arm)
LIBS +=-lpython2.6
endif
+ifeq (@USE_EXTERNAL_PYTHON@,1)
+LIBS += @PYTHON_LDFLAGS@
+endif
+
xbmc.bin: $(OBJSXBMC) $(DYNOBJSXBMC)
ifeq ($(findstring osx,@ARCH@), osx)
$(CXX) $(LDFLAGS) -o xbmc.bin -Wl,-all_load,-ObjC $(DYNOBJSXBMC) $(OBJSXBMC) $(LIBS) -rdynamic
diff --git a/XBMC.xcodeproj/project.pbxproj b/XBMC.xcodeproj/project.pbxproj
index cd56d940ae..1287265169 100644
--- a/XBMC.xcodeproj/project.pbxproj
+++ b/XBMC.xcodeproj/project.pbxproj
@@ -38,7 +38,7 @@
/* End PBXAggregateTarget section */
/* Begin PBXBuildFile section */
- 183C454D130C4D55006AA317 /* xbmcvfsmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 189047D11301DEAB00C11012 /* xbmcvfsmodule.cpp */; };
+ 183C454D130C4D55006AA317 /* xbmcvfsmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 189047D11301DEAB00C11012 /* xbmcvfsmodule.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
183FDF8A11AF0B0500B81E9C /* PluginSource.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 183FDF8811AF0B0500B81E9C /* PluginSource.cpp */; };
183FDF8B11AF0B0500B81E9C /* PluginSource.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 183FDF8811AF0B0500B81E9C /* PluginSource.cpp */; };
184C472F1296BC6E0006DB3E /* Service.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 184C472D1296BC6E0006DB3E /* Service.cpp */; };
@@ -363,6 +363,7 @@
18C1D22E13033F6A00CFFE59 /* GLUtils.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 18C1D22B13033F6A00CFFE59 /* GLUtils.cpp */; };
18CCEAEE1112F5B800615FC6 /* PCMRemap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 18CCEAEC1112F5B800615FC6 /* PCMRemap.cpp */; };
18CCEAEF1112F5B800615FC6 /* PCMRemap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 18CCEAEC1112F5B800615FC6 /* PCMRemap.cpp */; };
+ 384718D81325BA04000486D6 /* XBDateTime.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 384718D61325BA04000486D6 /* XBDateTime.cpp */; };
431AE5D9109C1A63007428C3 /* OverlayRendererUtil.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 431AE5D7109C1A63007428C3 /* OverlayRendererUtil.cpp */; };
431AE5DA109C1A63007428C3 /* OverlayRendererUtil.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 431AE5D7109C1A63007428C3 /* OverlayRendererUtil.cpp */; };
43248C4E0FBE224000B88866 /* LockFree.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 83A72B950FBC8E3B00171871 /* LockFree.cpp */; };
@@ -535,8 +536,8 @@
7CD2C3AB11940B270009EFC1 /* DirectoryNodeCountry.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2C3A811940B270009EFC1 /* DirectoryNodeCountry.cpp */; };
7CD2CD0111B38B000009EFC1 /* PythonAddon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2CCFE11B38B000009EFC1 /* PythonAddon.cpp */; };
7CD2CD0211B38B000009EFC1 /* xbmcaddonmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2CD0011B38B000009EFC1 /* xbmcaddonmodule.cpp */; };
- 7CD2CD0311B38B000009EFC1 /* PythonAddon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2CCFE11B38B000009EFC1 /* PythonAddon.cpp */; };
- 7CD2CD0411B38B000009EFC1 /* xbmcaddonmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2CD0011B38B000009EFC1 /* xbmcaddonmodule.cpp */; };
+ 7CD2CD0311B38B000009EFC1 /* PythonAddon.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2CCFE11B38B000009EFC1 /* PythonAddon.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ 7CD2CD0411B38B000009EFC1 /* xbmcaddonmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CD2CD0011B38B000009EFC1 /* xbmcaddonmodule.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
7CDAE9050FFCA3520040B25F /* DVDTSCorrection.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CDAE9030FFCA3520040B25F /* DVDTSCorrection.cpp */; };
7CDAE9060FFCA3520040B25F /* DVDTSCorrection.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CDAE9030FFCA3520040B25F /* DVDTSCorrection.cpp */; };
7CDAEA7D1001CD6E0040B25F /* karaokelyricstextustar.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CDAEA7B1001CD6E0040B25F /* karaokelyricstextustar.cpp */; };
@@ -568,10 +569,9 @@
889B4D8E0E0EF86C00FAD25E /* RSSDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 889B4D8C0E0EF86C00FAD25E /* RSSDirectory.cpp */; };
88ACB01B0DCF40800083CFDF /* ASAPFileDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 88ACB0190DCF40800083CFDF /* ASAPFileDirectory.cpp */; };
88ACB01F0DCF409E0083CFDF /* ASAPCodec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 88ACB01C0DCF409E0083CFDF /* ASAPCodec.cpp */; };
- 88D9FF600DD264B500EDA56F /* XBPythonDllFuncs.S in Sources */ = {isa = PBXBuildFile; fileRef = 88D9FF5F0DD264B500EDA56F /* XBPythonDllFuncs.S */; };
88ECB6590DE013C4003396A7 /* DiskArbitration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 88ECB6580DE013C4003396A7 /* DiskArbitration.framework */; };
8DD76F790486A8DE00D96B5E /* CoreFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 09AB6884FE841BABC02AAC07 /* CoreFoundation.framework */; };
- C80425711158A0DE00D158A6 /* controlslider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C80425701158A0DE00D158A6 /* controlslider.cpp */; };
+ C80425711158A0DE00D158A6 /* controlslider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C80425701158A0DE00D158A6 /* controlslider.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
C80425721158A0DE00D158A6 /* controlslider.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C80425701158A0DE00D158A6 /* controlslider.cpp */; };
C84BF7341349BB74006D6FC9 /* JSONServiceDescription.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C84BF7321349BB74006D6FC9 /* JSONServiceDescription.cpp */; };
C85EB75C1174614E0008E5A5 /* Repository.cpp in Sources */ = {isa = PBXBuildFile; fileRef = C85EB75A1174614E0008E5A5 /* Repository.cpp */; };
@@ -582,7 +582,7 @@
E33206380D5070AA00435CE3 /* DVDDemuxVobsub.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E33206370D5070AA00435CE3 /* DVDDemuxVobsub.cpp */; };
E33466A60D2E5103005A65EC /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E33466A50D2E5103005A65EC /* IOKit.framework */; };
E33979960D62FD48004ECDDA /* DVDInputStreamTV.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E33979940D62FD47004ECDDA /* DVDInputStreamTV.cpp */; };
- E354EF040D99EDC900B55311 /* controlradiobutton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E354EF030D99EDC900B55311 /* controlradiobutton.cpp */; };
+ E354EF040D99EDC900B55311 /* controlradiobutton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E354EF030D99EDC900B55311 /* controlradiobutton.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
E35EF2550D380C3D00DB5CD5 /* QuickTime.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E35EF2540D380C3D00DB5CD5 /* QuickTime.framework */; };
E35EF3240D380E1E00DB5CD5 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E35EF3230D380E1E00DB5CD5 /* Carbon.framework */; };
E36578880D3AA7B40033CC1C /* DVDPlayerCodec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E36578860D3AA7B40033CC1C /* DVDPlayerCodec.cpp */; };
@@ -689,7 +689,6 @@
E38E1FF10D25F9FD00618676 /* YUV2RGBShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16710D25F9FA00618676 /* YUV2RGBShader.cpp */; };
E38E1FF70D25F9FD00618676 /* CueDocument.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E167E0D25F9FA00618676 /* CueDocument.cpp */; };
E38E1FF80D25F9FD00618676 /* Database.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16800D25F9FA00618676 /* Database.cpp */; };
- E38E1FF90D25F9FD00618676 /* DateTime.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16820D25F9FA00618676 /* DateTime.cpp */; };
E38E1FFA0D25F9FD00618676 /* DetectDVDType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16840D25F9FA00618676 /* DetectDVDType.cpp */; };
E38E1FFB0D25F9FD00618676 /* DNSNameCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16890D25F9FA00618676 /* DNSNameCache.cpp */; };
E38E1FFC0D25F9FD00618676 /* DynamicDll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E168C0D25F9FA00618676 /* DynamicDll.cpp */; };
@@ -858,9 +857,8 @@
E38E20D60D25F9FD00618676 /* LangCodeExpander.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E18560D25F9FA00618676 /* LangCodeExpander.cpp */; };
E38E20D70D25F9FD00618676 /* LangInfo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E18580D25F9FA00618676 /* LangInfo.cpp */; };
E38E20D80D25F9FD00618676 /* LastFmManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E185A0D25F9FA00618676 /* LastFmManager.cpp */; };
- E38E21600D25F9FD00618676 /* XBPython.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A0D0D25F9FB00618676 /* XBPython.cpp */; };
- E38E21610D25F9FD00618676 /* XBPythonDll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A0F0D25F9FB00618676 /* XBPythonDll.cpp */; };
- E38E21620D25F9FD00618676 /* XBPyThread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A110D25F9FB00618676 /* XBPyThread.cpp */; };
+ E38E21600D25F9FD00618676 /* XBPython.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A0D0D25F9FB00618676 /* XBPython.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E21620D25F9FD00618676 /* XBPyThread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A110D25F9FB00618676 /* XBPyThread.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
E38E21670D25F9FD00618676 /* scrobbler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A250D25F9FB00618676 /* scrobbler.cpp */; };
E38E21740D25F9FD00618676 /* MediaCrawler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1ABD0D25F9FB00618676 /* MediaCrawler.cpp */; };
E38E21760D25F9FD00618676 /* PltMicroMediaController.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1AC20D25F9FB00618676 /* PltMicroMediaController.cpp */; };
@@ -1033,37 +1031,37 @@
E38E256D0D263A1C00618676 /* librtv.a in Frameworks */ = {isa = PBXBuildFile; fileRef = E38E256C0D263A1C00618676 /* librtv.a */; };
E38E25780D263BF600618676 /* unpack.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25770D263BF600618676 /* unpack.cpp */; };
E38E257C0D263C4400618676 /* rar.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E257B0D263C4400618676 /* rar.cpp */; };
- E38E259D0D263CE000618676 /* action.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E257E0D263CE000618676 /* action.cpp */; };
- E38E259E0D263CE000618676 /* control.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E257F0D263CE000618676 /* control.cpp */; };
- E38E259F0D263CE000618676 /* controlbutton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25800D263CE000618676 /* controlbutton.cpp */; };
- E38E25A00D263CE000618676 /* controlcheckmark.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25810D263CE000618676 /* controlcheckmark.cpp */; };
- E38E25A10D263CE000618676 /* controlfadelabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25820D263CE000618676 /* controlfadelabel.cpp */; };
- E38E25A20D263CE000618676 /* controlgroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25830D263CE000618676 /* controlgroup.cpp */; };
- E38E25A30D263CE000618676 /* controlimage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25840D263CE000618676 /* controlimage.cpp */; };
- E38E25A40D263CE000618676 /* controllabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25850D263CE000618676 /* controllabel.cpp */; };
- E38E25A50D263CE000618676 /* controllist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25860D263CE000618676 /* controllist.cpp */; };
- E38E25A60D263CE000618676 /* controlprogress.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25870D263CE000618676 /* controlprogress.cpp */; };
- E38E25A70D263CE000618676 /* controlspin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25880D263CE000618676 /* controlspin.cpp */; };
- E38E25A80D263CE000618676 /* controltextbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25890D263CE000618676 /* controltextbox.cpp */; };
- E38E25A90D263CE000618676 /* dialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258A0D263CE000618676 /* dialog.cpp */; };
- E38E25AA0D263CE000618676 /* GUIPythonWindow.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258B0D263CE000618676 /* GUIPythonWindow.cpp */; };
- E38E25AB0D263CE000618676 /* GUIPythonWindowDialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258C0D263CE000618676 /* GUIPythonWindowDialog.cpp */; };
- E38E25AC0D263CE000618676 /* GUIPythonWindowXML.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258D0D263CE000618676 /* GUIPythonWindowXML.cpp */; };
- E38E25AD0D263CE000618676 /* GUIPythonWindowXMLDialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258E0D263CE000618676 /* GUIPythonWindowXMLDialog.cpp */; };
- E38E25AE0D263CE000618676 /* infotagmusic.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258F0D263CE000618676 /* infotagmusic.cpp */; };
- E38E25AF0D263CE000618676 /* infotagvideo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25900D263CE000618676 /* infotagvideo.cpp */; };
- E38E25B00D263CE000618676 /* keyboard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25910D263CE000618676 /* keyboard.cpp */; };
- E38E25B10D263CE000618676 /* listitem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25920D263CE000618676 /* listitem.cpp */; };
- E38E25B20D263CE000618676 /* player.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25930D263CE000618676 /* player.cpp */; };
- E38E25B30D263CE000618676 /* pyplaylist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25940D263CE000618676 /* pyplaylist.cpp */; };
- E38E25B40D263CE000618676 /* PythonPlayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25950D263CE000618676 /* PythonPlayer.cpp */; };
- E38E25B50D263CE000618676 /* pyutil.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25960D263CE000618676 /* pyutil.cpp */; };
- E38E25B60D263CE000618676 /* window.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25970D263CE000618676 /* window.cpp */; };
- E38E25B70D263CE000618676 /* winxml.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25980D263CE000618676 /* winxml.cpp */; };
- E38E25B80D263CE000618676 /* winxmldialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25990D263CE000618676 /* winxmldialog.cpp */; };
- E38E25B90D263CE000618676 /* xbmcguimodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E259A0D263CE000618676 /* xbmcguimodule.cpp */; };
- E38E25BA0D263CE000618676 /* xbmcmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E259B0D263CE000618676 /* xbmcmodule.cpp */; };
- E38E25BB0D263CE000618676 /* xbmcplugin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E259C0D263CE000618676 /* xbmcplugin.cpp */; };
+ E38E259D0D263CE000618676 /* action.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E257E0D263CE000618676 /* action.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E259E0D263CE000618676 /* control.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E257F0D263CE000618676 /* control.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E259F0D263CE000618676 /* controlbutton.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25800D263CE000618676 /* controlbutton.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A00D263CE000618676 /* controlcheckmark.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25810D263CE000618676 /* controlcheckmark.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A10D263CE000618676 /* controlfadelabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25820D263CE000618676 /* controlfadelabel.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A20D263CE000618676 /* controlgroup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25830D263CE000618676 /* controlgroup.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A30D263CE000618676 /* controlimage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25840D263CE000618676 /* controlimage.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A40D263CE000618676 /* controllabel.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25850D263CE000618676 /* controllabel.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A50D263CE000618676 /* controllist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25860D263CE000618676 /* controllist.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A60D263CE000618676 /* controlprogress.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25870D263CE000618676 /* controlprogress.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A70D263CE000618676 /* controlspin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25880D263CE000618676 /* controlspin.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A80D263CE000618676 /* controltextbox.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25890D263CE000618676 /* controltextbox.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25A90D263CE000618676 /* dialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258A0D263CE000618676 /* dialog.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25AA0D263CE000618676 /* GUIPythonWindow.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258B0D263CE000618676 /* GUIPythonWindow.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25AB0D263CE000618676 /* GUIPythonWindowDialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258C0D263CE000618676 /* GUIPythonWindowDialog.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25AC0D263CE000618676 /* GUIPythonWindowXML.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258D0D263CE000618676 /* GUIPythonWindowXML.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25AD0D263CE000618676 /* GUIPythonWindowXMLDialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258E0D263CE000618676 /* GUIPythonWindowXMLDialog.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25AE0D263CE000618676 /* infotagmusic.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E258F0D263CE000618676 /* infotagmusic.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25AF0D263CE000618676 /* infotagvideo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25900D263CE000618676 /* infotagvideo.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B00D263CE000618676 /* keyboard.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25910D263CE000618676 /* keyboard.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B10D263CE000618676 /* listitem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25920D263CE000618676 /* listitem.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B20D263CE000618676 /* player.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25930D263CE000618676 /* player.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B30D263CE000618676 /* pyplaylist.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25940D263CE000618676 /* pyplaylist.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B40D263CE000618676 /* PythonPlayer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25950D263CE000618676 /* PythonPlayer.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B50D263CE000618676 /* pyutil.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25960D263CE000618676 /* pyutil.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B60D263CE000618676 /* window.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25970D263CE000618676 /* window.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B70D263CE000618676 /* winxml.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25980D263CE000618676 /* winxml.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B80D263CE000618676 /* winxmldialog.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25990D263CE000618676 /* winxmldialog.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25B90D263CE000618676 /* xbmcguimodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E259A0D263CE000618676 /* xbmcguimodule.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25BA0D263CE000618676 /* xbmcmodule.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E259B0D263CE000618676 /* xbmcmodule.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
+ E38E25BB0D263CE000618676 /* xbmcplugin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E259C0D263CE000618676 /* xbmcplugin.cpp */; settings = {COMPILER_FLAGS = "-I$XBMC_DEPENDS/include/python2.6"; }; };
E38E25C00D263DC100618676 /* DVDFactoryDemuxer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25BF0D263DC100618676 /* DVDFactoryDemuxer.cpp */; };
E38E25C30D263DE200618676 /* DVDDemuxFFmpeg.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E25C20D263DE200618676 /* DVDDemuxFFmpeg.cpp */; };
E38F12C20D29FF200035C331 /* FileShoutcast.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38F12C10D29FF200035C331 /* FileShoutcast.cpp */; };
@@ -1300,7 +1298,6 @@
F5A1C9370F6B06CF00A96ABD /* YUV2RGBShader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16710D25F9FA00618676 /* YUV2RGBShader.cpp */; };
F5A1C9390F6B06CF00A96ABD /* CueDocument.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E167E0D25F9FA00618676 /* CueDocument.cpp */; };
F5A1C93A0F6B06CF00A96ABD /* Database.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16800D25F9FA00618676 /* Database.cpp */; };
- F5A1C93B0F6B06CF00A96ABD /* DateTime.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16820D25F9FA00618676 /* DateTime.cpp */; };
F5A1C93C0F6B06CF00A96ABD /* DetectDVDType.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16840D25F9FA00618676 /* DetectDVDType.cpp */; };
F5A1C93D0F6B06CF00A96ABD /* DNSNameCache.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E16890D25F9FA00618676 /* DNSNameCache.cpp */; };
F5A1C93E0F6B06CF00A96ABD /* DynamicDll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E168C0D25F9FA00618676 /* DynamicDll.cpp */; };
@@ -1470,7 +1467,6 @@
F5A1C9FA0F6B06CF00A96ABD /* LangInfo.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E18580D25F9FA00618676 /* LangInfo.cpp */; };
F5A1C9FB0F6B06CF00A96ABD /* LastFmManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E185A0D25F9FA00618676 /* LastFmManager.cpp */; };
F5A1CA010F6B06CF00A96ABD /* XBPython.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A0D0D25F9FB00618676 /* XBPython.cpp */; };
- F5A1CA020F6B06CF00A96ABD /* XBPythonDll.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A0F0D25F9FB00618676 /* XBPythonDll.cpp */; };
F5A1CA030F6B06CF00A96ABD /* XBPyThread.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A110D25F9FB00618676 /* XBPyThread.cpp */; };
F5A1CA040F6B06CF00A96ABD /* scrobbler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1A250D25F9FB00618676 /* scrobbler.cpp */; };
F5A1CA050F6B06CF00A96ABD /* MediaCrawler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E38E1ABD0D25F9FB00618676 /* MediaCrawler.cpp */; };
@@ -1696,7 +1692,6 @@
F5A1CB520F6B06CF00A96ABD /* MusicFileDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 880DBE530DC224A100E26B71 /* MusicFileDirectory.cpp */; };
F5A1CB530F6B06CF00A96ABD /* ASAPFileDirectory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 88ACB0190DCF40800083CFDF /* ASAPFileDirectory.cpp */; };
F5A1CB540F6B06CF00A96ABD /* ASAPCodec.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 88ACB01C0DCF409E0083CFDF /* ASAPCodec.cpp */; };
- F5A1CB560F6B06CF00A96ABD /* XBPythonDllFuncs.S in Sources */ = {isa = PBXBuildFile; fileRef = 88D9FF5F0DD264B500EDA56F /* XBPythonDllFuncs.S */; };
F5A1CB570F6B06CF00A96ABD /* DVDOverlayCodecSSA.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8883CE9E0DD817D1004E8B72 /* DVDOverlayCodecSSA.cpp */; };
F5A1CB580F6B06CF00A96ABD /* DVDSubtitleParserSSA.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8883CEA30DD81807004E8B72 /* DVDSubtitleParserSSA.cpp */; };
F5A1CB590F6B06CF00A96ABD /* DVDSubtitlesLibass.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 8883CEA50DD81807004E8B72 /* DVDSubtitlesLibass.cpp */; };
@@ -2255,6 +2250,8 @@
18C1D22C13033F6A00CFFE59 /* GLUtils.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GLUtils.h; sourceTree = "<group>"; };
18CCEAEC1112F5B800615FC6 /* PCMRemap.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = PCMRemap.cpp; sourceTree = "<group>"; };
18CCEAED1112F5B800615FC6 /* PCMRemap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PCMRemap.h; sourceTree = "<group>"; };
+ 384718D61325BA04000486D6 /* XBDateTime.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = XBDateTime.cpp; sourceTree = "<group>"; };
+ 384718D71325BA04000486D6 /* XBDateTime.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XBDateTime.h; sourceTree = "<group>"; };
38B2BBD013131B4A00F83309 /* GlobalsHandling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GlobalsHandling.h; sourceTree = "<group>"; };
430C881312D64A730098821A /* IPowerSyscall.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IPowerSyscall.h; sourceTree = "<group>"; };
431376FF12D6455C00680C15 /* GUIDialogCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GUIDialogCache.h; sourceTree = "<group>"; };
@@ -2511,7 +2508,6 @@
88ACB01C0DCF409E0083CFDF /* ASAPCodec.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ASAPCodec.cpp; sourceTree = "<group>"; };
88ACB01D0DCF409E0083CFDF /* ASAPCodec.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ASAPCodec.h; sourceTree = "<group>"; };
88ACB01E0DCF409E0083CFDF /* DllASAP.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DllASAP.h; sourceTree = "<group>"; };
- 88D9FF5F0DD264B500EDA56F /* XBPythonDllFuncs.S */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.asm; path = XBPythonDllFuncs.S; sourceTree = "<group>"; };
88ECB6580DE013C4003396A7 /* DiskArbitration.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = DiskArbitration.framework; path = /System/Library/Frameworks/DiskArbitration.framework; sourceTree = "<absolute>"; };
8DD76F7E0486A8DE00D96B5E /* XBMC */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = XBMC; sourceTree = BUILT_PRODUCTS_DIR; };
C80425701158A0DE00D158A6 /* controlslider.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = controlslider.cpp; sourceTree = "<group>"; };
@@ -2781,8 +2777,6 @@
E38E167F0D25F9FA00618676 /* CueDocument.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CueDocument.h; sourceTree = "<group>"; };
E38E16800D25F9FA00618676 /* Database.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = Database.cpp; sourceTree = "<group>"; };
E38E16810D25F9FA00618676 /* Database.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Database.h; sourceTree = "<group>"; };
- E38E16820D25F9FA00618676 /* DateTime.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DateTime.cpp; sourceTree = "<group>"; };
- E38E16830D25F9FA00618676 /* DateTime.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DateTime.h; sourceTree = "<group>"; };
E38E16840D25F9FA00618676 /* DetectDVDType.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DetectDVDType.cpp; sourceTree = "<group>"; };
E38E16850D25F9FA00618676 /* DetectDVDType.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DetectDVDType.h; sourceTree = "<group>"; };
E38E16860D25F9FA00618676 /* DllImageLib.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DllImageLib.h; sourceTree = "<group>"; };
@@ -3155,7 +3149,6 @@
E38E1A080D25F9FB00618676 /* winxml.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = winxml.h; sourceTree = "<group>"; };
E38E1A0D0D25F9FB00618676 /* XBPython.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = XBPython.cpp; sourceTree = "<group>"; };
E38E1A0E0D25F9FB00618676 /* XBPython.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XBPython.h; sourceTree = "<group>"; };
- E38E1A0F0D25F9FB00618676 /* XBPythonDll.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = XBPythonDll.cpp; sourceTree = "<group>"; };
E38E1A100D25F9FB00618676 /* XBPythonDll.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XBPythonDll.h; sourceTree = "<group>"; };
E38E1A110D25F9FB00618676 /* XBPyThread.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = XBPyThread.cpp; sourceTree = "<group>"; };
E38E1A120D25F9FB00618676 /* XBPyThread.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XBPyThread.h; sourceTree = "<group>"; };
@@ -5028,8 +5021,6 @@
E38E14730D25F9F900618676 /* BackgroundInfoLoader.h */,
E38E167E0D25F9FA00618676 /* CueDocument.cpp */,
E38E167F0D25F9FA00618676 /* CueDocument.h */,
- E38E16820D25F9FA00618676 /* DateTime.cpp */,
- E38E16830D25F9FA00618676 /* DateTime.h */,
E38E168C0D25F9FA00618676 /* DynamicDll.cpp */,
E38E168D0D25F9FA00618676 /* DynamicDll.h */,
E38E16900D25F9FA00618676 /* Favourites.cpp */,
@@ -5082,6 +5073,8 @@
E38E1E9A0D25F9FD00618676 /* ViewDatabase.h */,
E38E1EA70D25F9FD00618676 /* XBApplicationEx.cpp */,
E38E1EA80D25F9FD00618676 /* XBApplicationEx.h */,
+ 384718D61325BA04000486D6 /* XBDateTime.cpp */,
+ 384718D71325BA04000486D6 /* XBDateTime.h */,
E38E1ED10D25F9FD00618676 /* xbmc.cpp */,
);
path = xbmc;
@@ -5927,11 +5920,9 @@
E38E19820D25F9FB00618676 /* python */ = {
isa = PBXGroup;
children = (
- 88D9FF5F0DD264B500EDA56F /* XBPythonDllFuncs.S */,
E38E19DA0D25F9FB00618676 /* xbmcmodule */,
E38E1A0D0D25F9FB00618676 /* XBPython.cpp */,
E38E1A0E0D25F9FB00618676 /* XBPython.h */,
- E38E1A0F0D25F9FB00618676 /* XBPythonDll.cpp */,
E38E1A100D25F9FB00618676 /* XBPythonDll.h */,
E38E1A110D25F9FB00618676 /* XBPyThread.cpp */,
E38E1A120D25F9FB00618676 /* XBPyThread.h */,
@@ -7361,7 +7352,6 @@
E38E1FF10D25F9FD00618676 /* YUV2RGBShader.cpp in Sources */,
E38E1FF70D25F9FD00618676 /* CueDocument.cpp in Sources */,
E38E1FF80D25F9FD00618676 /* Database.cpp in Sources */,
- E38E1FF90D25F9FD00618676 /* DateTime.cpp in Sources */,
E38E1FFA0D25F9FD00618676 /* DetectDVDType.cpp in Sources */,
E38E1FFB0D25F9FD00618676 /* DNSNameCache.cpp in Sources */,
E38E1FFC0D25F9FD00618676 /* DynamicDll.cpp in Sources */,
@@ -7531,7 +7521,6 @@
E38E20D70D25F9FD00618676 /* LangInfo.cpp in Sources */,
E38E20D80D25F9FD00618676 /* LastFmManager.cpp in Sources */,
E38E21600D25F9FD00618676 /* XBPython.cpp in Sources */,
- E38E21610D25F9FD00618676 /* XBPythonDll.cpp in Sources */,
E38E21620D25F9FD00618676 /* XBPyThread.cpp in Sources */,
E38E21670D25F9FD00618676 /* scrobbler.cpp in Sources */,
E38E21740D25F9FD00618676 /* MediaCrawler.cpp in Sources */,
@@ -7757,7 +7746,6 @@
880DBE550DC224A100E26B71 /* MusicFileDirectory.cpp in Sources */,
88ACB01B0DCF40800083CFDF /* ASAPFileDirectory.cpp in Sources */,
88ACB01F0DCF409E0083CFDF /* ASAPCodec.cpp in Sources */,
- 88D9FF600DD264B500EDA56F /* XBPythonDllFuncs.S in Sources */,
8883CEA10DD817D1004E8B72 /* DVDOverlayCodecSSA.cpp in Sources */,
8883CEA70DD81807004E8B72 /* DVDSubtitleParserSSA.cpp in Sources */,
8883CEA80DD81807004E8B72 /* DVDSubtitlesLibass.cpp in Sources */,
@@ -8149,6 +8137,7 @@
F5AE40A713415D9E0004BD79 /* VideoLibrary.cpp in Sources */,
F5AE40A813415D9E0004BD79 /* XBMCOperations.cpp in Sources */,
C84BF7341349BB74006D6FC9 /* JSONServiceDescription.cpp in Sources */,
+ 384718D81325BA04000486D6 /* XBDateTime.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -8252,7 +8241,6 @@
F5A1C9370F6B06CF00A96ABD /* YUV2RGBShader.cpp in Sources */,
F5A1C9390F6B06CF00A96ABD /* CueDocument.cpp in Sources */,
F5A1C93A0F6B06CF00A96ABD /* Database.cpp in Sources */,
- F5A1C93B0F6B06CF00A96ABD /* DateTime.cpp in Sources */,
F5A1C93C0F6B06CF00A96ABD /* DetectDVDType.cpp in Sources */,
F5A1C93D0F6B06CF00A96ABD /* DNSNameCache.cpp in Sources */,
F5A1C93E0F6B06CF00A96ABD /* DynamicDll.cpp in Sources */,
@@ -8422,7 +8410,6 @@
F5A1C9FA0F6B06CF00A96ABD /* LangInfo.cpp in Sources */,
F5A1C9FB0F6B06CF00A96ABD /* LastFmManager.cpp in Sources */,
F5A1CA010F6B06CF00A96ABD /* XBPython.cpp in Sources */,
- F5A1CA020F6B06CF00A96ABD /* XBPythonDll.cpp in Sources */,
F5A1CA030F6B06CF00A96ABD /* XBPyThread.cpp in Sources */,
F5A1CA040F6B06CF00A96ABD /* scrobbler.cpp in Sources */,
F5A1CA050F6B06CF00A96ABD /* MediaCrawler.cpp in Sources */,
@@ -8648,7 +8635,6 @@
F5A1CB520F6B06CF00A96ABD /* MusicFileDirectory.cpp in Sources */,
F5A1CB530F6B06CF00A96ABD /* ASAPFileDirectory.cpp in Sources */,
F5A1CB540F6B06CF00A96ABD /* ASAPCodec.cpp in Sources */,
- F5A1CB560F6B06CF00A96ABD /* XBPythonDllFuncs.S in Sources */,
F5A1CB570F6B06CF00A96ABD /* DVDOverlayCodecSSA.cpp in Sources */,
F5A1CB580F6B06CF00A96ABD /* DVDSubtitleParserSSA.cpp in Sources */,
F5A1CB590F6B06CF00A96ABD /* DVDSubtitlesLibass.cpp in Sources */,
diff --git a/configure.in b/configure.in
index e98e383dfa..10b9cd0aee 100644
--- a/configure.in
+++ b/configure.in
@@ -5,6 +5,7 @@ AC_PREREQ(2.59)
AC_INIT([xbmc], [9.11], [http://trac.xbmc.org])
AC_CONFIG_HEADERS([xbmc/config.h])
AH_TOP([#pragma once])
+m4_include([m4/ax_python_devel.m4])
AC_CONFIG_AUX_DIR([build-aux])
AM_INIT_AUTOMAKE([foreign])
@@ -891,29 +892,21 @@ fi
# External Python
if test "$use_external_python" = "yes"; then
- AC_CHECK_LIB([python2.6], [main],
- [AC_DEFINE([HAVE_LIBPYTHON2_6], [1],
- [Define to 1 if you have the 'python2.6' library.])
- USE_PYTHON2_6=1],
- [AC_CHECK_LIB([python2.5], [main],
- [AC_DEFINE([HAVE_LIBPYTHON2_5], [1],
- [Define to 1 if you have the 'python2.5' library.])
- USE_PYTHON2_5=1],
- [AC_CHECK_LIB([python2.4], [main],
- [AC_DEFINE([HAVE_LIBPYTHON2_4], [1],
- [Define to 1 if you have the 'python2.4' library.])
- USE_PYTHON2_4=1],
- [AC_MSG_ERROR($missing_library)] )] )] )
-
- AC_MSG_NOTICE($external_python_enabled)
- test "$USE_PYTHON2_6" && AC_MSG_NOTICE([Using Python 2.6])
- test "$USE_PYTHON2_5" && AC_MSG_NOTICE([Using Python 2.5])
- test "$USE_PYTHON2_4" && AC_MSG_NOTICE([Using Python 2.4])
- USE_EXTERNAL_PYTHON=1
- AC_DEFINE([USE_EXTERNAL_PYTHON], [1], [Whether to use external python library.])
+ AX_PYTHON_DEVEL([>= 2.4])
+ PYTHON_VERSION=$ac_python_version
+
+ if test -z "$PYTHON_VERSION"; then
+ AC_MSG_NOTICE($external_python_disabled)
+ USE_EXTERNAL_PYTHON=0
+ else
+ AC_MSG_NOTICE($external_python_enabled)
+ AC_MSG_NOTICE([Using Python $PYTHON_VERSION])
+ USE_EXTERNAL_PYTHON=1
+ AC_DEFINE([USE_EXTERNAL_PYTHON], [1], [Whether to use external python library.])
+ fi
else
- AC_MSG_NOTICE($external_python_disabled)
USE_EXTERNAL_PYTHON=0
+ PYTHON_CPPFLAGS="-I\$(abs_top_srcdir)/lib/python/Include"
fi
# VDPAU
@@ -1401,7 +1394,8 @@ OUTPUT_FILES="Makefile \
lib/libsquish/Makefile \
lib/libid3tag/Makefile \
lib/cximage-6.0/Makefile \
- xbmc/interfaces/python/linux/Makefile \
+ xbmc/interfaces/python/Makefile \
+ xbmc/interfaces/python/xbmcmodule/Makefile \
lib/libUPnP/Makefile \
xbmc/DllPaths_generated.h \
xbmc/linux/Makefile \
@@ -1434,9 +1428,7 @@ AC_SUBST(BUILD_DVDCSS)
AC_SUBST(BUILD_GOOM)
AC_SUBST(USE_EXTERNAL_FFMPEG)
AC_SUBST(USE_EXTERNAL_PYTHON)
-AC_SUBST(USE_PYTHON2_6)
-AC_SUBST(USE_PYTHON2_5)
-AC_SUBST(USE_PYTHON2_4)
+AC_SUBST(PYTHON_VERSION)
AC_SUBST(OUTPUT_FILES)
AC_SUBST(HAVE_XBMC_NONFREE)
AC_SUBST(USE_ASAP_CODEC)
diff --git a/m4/ax_python_devel.m4 b/m4/ax_python_devel.m4
new file mode 100644
index 0000000000..adbd207475
--- /dev/null
+++ b/m4/ax_python_devel.m4
@@ -0,0 +1,333 @@
+# ===========================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_python_devel.html
+# ===========================================================================
+#
+# SYNOPSIS
+#
+# AX_PYTHON_DEVEL([version])
+#
+# DESCRIPTION
+#
+# Note: Defines as a precious variable "PYTHON_VERSION". Don't override it
+# in your configure.ac.
+#
+# This macro checks for Python and tries to get the include path to
+# 'Python.h'. It provides the $(PYTHON_CPPFLAGS) and $(PYTHON_LDFLAGS)
+# output variables. It also exports $(PYTHON_EXTRA_LIBS) and
+# $(PYTHON_EXTRA_LDFLAGS) for embedding Python in your code.
+#
+# You can search for some particular version of Python by passing a
+# parameter to this macro, for example ">= '2.3.1'", or "== '2.4'". Please
+# note that you *have* to pass also an operator along with the version to
+# match, and pay special attention to the single quotes surrounding the
+# version number. Don't use "PYTHON_VERSION" for this: that environment
+# variable is declared as precious and thus reserved for the end-user.
+#
+# This macro should work for all versions of Python >= 2.1.0. As an end
+# user, you can disable the check for the python version by setting the
+# PYTHON_NOVERSIONCHECK environment variable to something else than the
+# empty string.
+#
+# If you need to use this macro for an older Python version, please
+# contact the authors. We're always open for feedback.
+#
+# LICENSE
+#
+# Copyright (c) 2009 Sebastian Huber <sebastian-huber@web.de>
+# Copyright (c) 2009 Alan W. Irwin <irwin@beluga.phys.uvic.ca>
+# Copyright (c) 2009 Rafael Laboissiere <rafael@laboissiere.net>
+# Copyright (c) 2009 Andrew Collier <colliera@ukzn.ac.za>
+# Copyright (c) 2009 Matteo Settenvini <matteo@member.fsf.org>
+# Copyright (c) 2009 Horst Knorr <hk_classes@knoda.org>
+#
+# This program is free software: you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by the
+# Free Software Foundation, either version 3 of the License, or (at your
+# option) any later version.
+#
+# This program 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 General
+# Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+# As a special exception, the respective Autoconf Macro's copyright owner
+# gives unlimited permission to copy, distribute and modify the configure
+# scripts that are the output of Autoconf when processing the Macro. You
+# need not follow the terms of the GNU General Public License when using
+# or distributing such scripts, even though portions of the text of the
+# Macro appear in them. The GNU General Public License (GPL) does govern
+# all other use of the material that constitutes the Autoconf Macro.
+#
+# This special exception to the GPL applies to versions of the Autoconf
+# Macro released by the Autoconf Archive. When you make and distribute a
+# modified version of the Autoconf Macro, you may extend this special
+# exception to the GPL to apply to your modified version as well.
+
+#serial 8
+
+AU_ALIAS([AC_PYTHON_DEVEL], [AX_PYTHON_DEVEL])
+AC_DEFUN([AX_PYTHON_DEVEL],[
+ #
+ # Allow the use of a (user set) custom python version
+ #
+ AC_ARG_VAR([PYTHON_VERSION],[The installed Python
+ version to use, for example '2.3'. This string
+ will be appended to the Python interpreter
+ canonical name.])
+
+ AC_PATH_PROG([PYTHON],[python[$PYTHON_VERSION]])
+ if test -z "$PYTHON"; then
+ AC_MSG_ERROR([Cannot find python$PYTHON_VERSION in your system path])
+ PYTHON_VERSION=""
+ fi
+
+ #
+ # Check for a version of Python >= 2.1.0
+ #
+ AC_MSG_CHECKING([for a version of Python >= '2.1.0'])
+ ac_supports_python_ver=`$PYTHON -c "import sys; \
+ ver = sys.version.split ()[[0]]; \
+ print (ver >= '2.1.0')"`
+ if test "$ac_supports_python_ver" != "True"; then
+ if test -z "$PYTHON_NOVERSIONCHECK"; then
+ AC_MSG_RESULT([no])
+ AC_MSG_FAILURE([
+This version of the AC@&t@_PYTHON_DEVEL macro
+doesn't work properly with versions of Python before
+2.1.0. You may need to re-run configure, setting the
+variables PYTHON_CPPFLAGS, PYTHON_LDFLAGS, PYTHON_SITE_PKG,
+PYTHON_EXTRA_LIBS and PYTHON_EXTRA_LDFLAGS by hand.
+Moreover, to disable this check, set PYTHON_NOVERSIONCHECK
+to something else than an empty string.
+])
+ else
+ AC_MSG_RESULT([skip at user request])
+ fi
+ else
+ AC_MSG_RESULT([yes])
+ fi
+
+ #
+ # if the macro parameter ``version'' is set, honour it
+ #
+ if test -n "$1"; then
+ AC_MSG_CHECKING([for a version of Python $1])
+ ac_supports_python_ver=`$PYTHON -c "import sys; \
+ ver = sys.version.split ()[[0]]; \
+ print (ver $1)"`
+ if test "$ac_supports_python_ver" = "True"; then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ AC_MSG_ERROR([this package requires Python $1.
+If you have it installed, but it isn't the default Python
+interpreter in your system path, please pass the PYTHON_VERSION
+variable to configure. See ``configure --help'' for reference.
+])
+ PYTHON_VERSION=""
+ fi
+ fi
+
+ #
+ # Check if you have distutils, else fail
+ #
+ AC_MSG_CHECKING([for the distutils Python package])
+ ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
+ if test -z "$ac_distutils_result"; then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ AC_MSG_ERROR([cannot import Python module "distutils".
+Please check your Python installation. The error was:
+$ac_distutils_result])
+ PYTHON_VERSION=""
+ fi
+
+ #
+ # Check for Python include path
+ #
+ AC_MSG_CHECKING([for Python include path])
+ if test -z "$PYTHON_CPPFLAGS"; then
+ python_path=`$PYTHON -c "import distutils.sysconfig; \
+ print (distutils.sysconfig.get_python_inc ());"`
+ if test -n "${python_path}"; then
+ python_path="-I$python_path"
+ fi
+ PYTHON_CPPFLAGS=$python_path
+ fi
+ AC_MSG_RESULT([$PYTHON_CPPFLAGS])
+ AC_SUBST([PYTHON_CPPFLAGS])
+
+ #
+ # Check for Python library path
+ #
+ AC_MSG_CHECKING([for Python library path])
+ if test -z "$PYTHON_LDFLAGS"; then
+ # (makes two attempts to ensure we've got a version number
+ # from the interpreter)
+ ac_python_version=`cat<<EOD | $PYTHON -
+
+# join all versioning strings, on some systems
+# major/minor numbers could be in different list elements
+from distutils.sysconfig import *
+ret = ''
+for e in get_config_vars ('VERSION'):
+ if (e != None):
+ ret += e
+print (ret)
+EOD`
+
+ if test -z "$ac_python_version"; then
+ if test -n "$PYTHON_VERSION"; then
+ ac_python_version=$PYTHON_VERSION
+ else
+ ac_python_version=`$PYTHON -c "import sys; \
+ print (sys.version[[:3]])"`
+ fi
+ fi
+
+ # Make the versioning information available to the compiler
+ AC_DEFINE_UNQUOTED([HAVE_PYTHON], ["$ac_python_version"],
+ [If available, contains the Python version number currently in use.])
+
+ # First, the library directory:
+ ac_python_libdir=`cat<<EOD | $PYTHON -
+
+# There should be only one
+import distutils.sysconfig
+for e in distutils.sysconfig.get_config_vars ('LIBDIR'):
+ if e != None:
+ print (e)
+ break
+EOD`
+
+ # Before checking for libpythonX.Y, we need to know
+ # the extension the OS we're on uses for libraries
+ # (we take the first one, if there's more than one fix me!):
+ ac_python_soext=`$PYTHON -c \
+ "import distutils.sysconfig; \
+ print (distutils.sysconfig.get_config_vars('SO')[[0]])"`
+
+ # Now, for the library:
+ ac_python_soname=`$PYTHON -c \
+ "import distutils.sysconfig; \
+ print (distutils.sysconfig.get_config_vars('LDLIBRARY')[[0]])"`
+
+ # If we're on OS X and this is a .dylib then the distutils will
+ # identify the .so extension incorrectly. So we check if the
+ # the extension is .dylib
+ PYTHON_LIB_IS_NOT_OSX_DYLIB=`echo "$ac_python_soname" | sed "s/^.*\.dylib$//"`
+ if test -z "$PYTHON_LIB_IS_NOT_OSX_DYLIB"; then
+ ac_python_soext=".dylib"
+ fi
+
+ # Strip away extension from the end to canonicalize its name:
+ ac_python_library=`echo "$ac_python_soname" | sed "s/${ac_python_soext}$//"`
+
+ # This small piece shamelessly adapted from PostgreSQL python macro;
+ # credits goes to momjian, I think. I'd like to put the right name
+ # in the credits, if someone can point me in the right direction... ?
+ #
+ if test -n "$ac_python_libdir" -a -n "$ac_python_library" \
+ -a x"$ac_python_library" != x"$ac_python_soname"
+ then
+ # use the official shared library
+ ac_python_library=`echo "$ac_python_library" | sed "s/^lib//"`
+ PYTHON_LDFLAGS="-L$ac_python_libdir -l$ac_python_library"
+ else
+ # old way: use libpython from python_configdir
+ ac_python_libdir=`$PYTHON -c \
+ "from distutils.sysconfig import get_python_lib as f; \
+ import os; \
+ print (os.path.join(f(plat_specific=1, standard_lib=1), 'config'));"`
+ PYTHON_LDFLAGS="-L$ac_python_libdir -lpython$ac_python_version"
+ fi
+
+ if test -z "$PYTHON_LDFLAGS"; then
+ AC_MSG_ERROR([
+ Cannot determine location of your Python DSO. Please check it was installed with
+ dynamic libraries enabled, or try setting PYTHON_LDFLAGS by hand.
+ ])
+ fi
+ fi
+ AC_MSG_RESULT([$PYTHON_LDFLAGS])
+ AC_SUBST([PYTHON_LDFLAGS])
+
+ #
+ # Check for site packages
+ #
+ AC_MSG_CHECKING([for Python site-packages path])
+ if test -z "$PYTHON_SITE_PKG"; then
+ PYTHON_SITE_PKG=`$PYTHON -c "import distutils.sysconfig; \
+ print (distutils.sysconfig.get_python_lib(0,0));"`
+ fi
+ AC_MSG_RESULT([$PYTHON_SITE_PKG])
+ AC_SUBST([PYTHON_SITE_PKG])
+
+ #
+ # libraries which must be linked in when embedding
+ #
+ AC_MSG_CHECKING(python extra libraries)
+ if test -z "$PYTHON_EXTRA_LIBS"; then
+ PYTHON_EXTRA_LIBS=`$PYTHON -c "import distutils.sysconfig; \
+ conf = distutils.sysconfig.get_config_var; \
+ print (conf('LOCALMODLIBS') + ' ' + conf('LIBS'))"`
+ fi
+ AC_MSG_RESULT([$PYTHON_EXTRA_LIBS])
+ AC_SUBST(PYTHON_EXTRA_LIBS)
+
+ #
+ # linking flags needed when embedding
+ #
+ AC_MSG_CHECKING(python extra linking flags)
+ if test -z "$PYTHON_EXTRA_LDFLAGS"; then
+ PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import distutils.sysconfig; \
+ conf = distutils.sysconfig.get_config_var; \
+ print (conf('LINKFORSHARED'))"`
+ fi
+ AC_MSG_RESULT([$PYTHON_EXTRA_LDFLAGS])
+ AC_SUBST(PYTHON_EXTRA_LDFLAGS)
+
+ #
+ # final check to see if everything compiles alright
+ #
+ AC_MSG_CHECKING([consistency of all components of python development environment])
+ # save current global flags
+ ac_save_LIBS="$LIBS"
+ ac_save_CPPFLAGS="$CPPFLAGS"
+ LIBS="$ac_save_LIBS $PYTHON_LDFLAGS $PYTHON_EXTRA_LDFLAGS $PYTHON_EXTRA_LIBS"
+ CPPFLAGS="$ac_save_CPPFLAGS $PYTHON_CPPFLAGS"
+ AC_LANG_PUSH([C])
+ AC_LINK_IFELSE([
+ AC_LANG_PROGRAM([[#include <Python.h>]],
+ [[Py_Initialize();]])
+ ],[pythonexists=yes],[pythonexists=no])
+ AC_LANG_POP([C])
+ # turn back to default flags
+ CPPFLAGS="$ac_save_CPPFLAGS"
+ LIBS="$ac_save_LIBS"
+
+ AC_MSG_RESULT([$pythonexists])
+
+ if test ! "x$pythonexists" = "xyes"; then
+ AC_MSG_FAILURE([
+ Could not link test program to Python. Maybe the main Python library has been
+ installed in some non-standard library path. If so, pass it to configure,
+ via the LDFLAGS environment variable.
+ Example: ./configure LDFLAGS="-L/usr/non-standard-path/python/lib"
+ ============================================================================
+ ERROR!
+ You probably have to install the development version of the Python package
+ for your distribution. The exact name of this package varies among them.
+ ============================================================================
+ ])
+ PYTHON_VERSION=""
+ fi
+
+ #
+ # all done!
+ #
+])
diff --git a/project/VS2010Express/XBMC.vcxproj b/project/VS2010Express/XBMC.vcxproj
index c8ae1bb7b1..499fbae075 100644
--- a/project/VS2010Express/XBMC.vcxproj
+++ b/project/VS2010Express/XBMC.vcxproj
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug (DirectX)|Win32">
@@ -147,7 +147,7 @@
<ClCompile>
<Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>..\..\;..\..\xbmc\;..\..\xbmc\win32\;..\..\xbmc\cores\dvdplayer;..\..\lib;..\..\lib\ffmpeg;..\..\lib\ffmpeg\include-xbmc-win32;..\..\lib\freetype\include;..\..\lib\jsoncpp\jsoncpp\include;..\..\lib\liblame\include;..\..\lib\libUPnP\Platinum\Source\Devices\MediaRenderer;..\..\lib\libUPnP\Platinum\Source\Devices\MediaConnect;..\..\lib\libUPnP\Platinum\Source\Devices\MediaServer;..\..\lib\libUPnP\Platinum\Source\Platinum;..\..\lib\libUPnP\Platinum\Source\Core;..\..\lib\libUPnP\Neptune\Source\Core;..\..\lib\libUPnP\Neptune\Source\System\Win32;..\..\lib\Python\PC;..\..\lib\win32\boost;..\..\lib\win32\libbluray_win32;..\..\lib\win32\libcdio\include;..\..\lib\win32\libiconv\include;..\..\lib\win32\libmicrohttpd_win32\include;..\..\lib\win32\libwavpack;..\..\lib\win32\pcre;..\..\lib\win32\vorbisfile\libvorbis\include;..\..\lib\win32\vorbisfile\ogg\include;..\..\lib\jsoncpp\include</AdditionalIncludeDirectories>
- <PreprocessorDefinitions>_WINDOWS;_MSVC;WIN32;_DEBUG;_WIN32_WINNT=0x0501;WINVER=0x0500;NOMINMAX;_USE_32BIT_TIME_T;HAS_DX;Py_NO_ENABLE_SHARED;D3D_DEBUG_INFO;__STDC_CONSTANT_MACROS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>_WINDOWS;_MSVC;WIN32;_DEBUG;_WIN32_WINNT=0x0501;WINVER=0x0500;NOMINMAX;_USE_32BIT_TIME_T;HAS_DX;Py_NO_ENABLE_SHARED;USE_EXTERNAL_PYTHON;D3D_DEBUG_INFO;__STDC_CONSTANT_MACROS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<ExceptionHandling>Async</ExceptionHandling>
<BasicRuntimeChecks>Default</BasicRuntimeChecks>
@@ -303,7 +303,6 @@
<ClCompile Include="..\..\xbmc\cores\VideoRenderers\RenderCapture.cpp" />
<ClCompile Include="..\..\xbmc\cores\VideoRenderers\VideoShaders\WinVideoFilter.cpp" />
<ClCompile Include="..\..\xbmc\CueDocument.cpp" />
- <ClCompile Include="..\..\xbmc\DateTime.cpp" />
<ClCompile Include="..\..\xbmc\dbwrappers\Database.cpp" />
<ClCompile Include="..\..\xbmc\dbwrappers\dataset.cpp" />
<ClCompile Include="..\..\xbmc\dbwrappers\mysqldataset.cpp" />
@@ -739,7 +738,6 @@
<ClCompile Include="..\..\xbmc\win32\strverscmp.cpp" />
<ClCompile Include="..\..\xbmc\win32\Win32DelayedDllLoad.cpp" />
<ClCompile Include="..\..\xbmc\win32\WIN32Util.cpp" />
- <ClCompile Include="..\..\xbmc\win32\WIN32XBPythonDll.cpp" />
<ClCompile Include="..\..\xbmc\win32\WINDirectSound.cpp" />
<ClCompile Include="..\..\xbmc\win32\WindowHelper.cpp" />
<ClCompile Include="..\..\xbmc\win32\WINFileSMB.cpp" />
@@ -1079,6 +1077,7 @@
<ClCompile Include="..\..\xbmc\windows\GUIWindowSystemInfo.cpp" />
<ClCompile Include="..\..\xbmc\windows\GUIWindowWeather.cpp" />
<ClCompile Include="..\..\xbmc\XBApplicationEx.cpp" />
+ <ClCompile Include="..\..\xbmc\XBDateTime.cpp" />
<ClCompile Include="..\..\xbmc\xbmc.cpp" />
</ItemGroup>
<ItemGroup>
@@ -1106,7 +1105,6 @@
<ClInclude Include="..\..\xbmc\cores\VideoRenderers\RenderCapture.h" />
<ClInclude Include="..\..\xbmc\cores\VideoRenderers\VideoShaders\WinVideoFilter.h" />
<ClInclude Include="..\..\xbmc\CueDocument.h" />
- <ClInclude Include="..\..\xbmc\DateTime.h" />
<ClInclude Include="..\..\xbmc\dbwrappers\Database.h" />
<ClInclude Include="..\..\xbmc\dbwrappers\dataset.h" />
<ClInclude Include="..\..\xbmc\dbwrappers\mysqldataset.h" />
@@ -1565,6 +1563,7 @@
<ClInclude Include="..\..\xbmc\ViewState.h" />
<ClInclude Include="..\..\xbmc\win32\pch.h" />
<ClInclude Include="..\..\xbmc\win32\PlatformDefs.h" />
+ <ClInclude Include="..\..\xbmc\XBDateTime.h" />
<CustomBuild Include="..\..\xbmc\win32\PlatformInclude.h">
<Command Condition="'$(Configuration)|$(Platform)'=='Release (DirectX)|Win32'">update_git_rev.bat</Command>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release (DirectX)|Win32'">..\..\xbmc\win32\git_rev.h;%(Outputs)</Outputs>
diff --git a/project/VS2010Express/XBMC.vcxproj.filters b/project/VS2010Express/XBMC.vcxproj.filters
index 2016f9a728..283046a997 100644
--- a/project/VS2010Express/XBMC.vcxproj.filters
+++ b/project/VS2010Express/XBMC.vcxproj.filters
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>
+<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="win32">
@@ -1529,9 +1529,6 @@
<ClCompile Include="..\..\xbmc\interfaces\python\XBPyThread.cpp">
<Filter>interfaces\python</Filter>
</ClCompile>
- <ClCompile Include="..\..\xbmc\win32\WIN32XBPythonDll.cpp">
- <Filter>interfaces\python</Filter>
- </ClCompile>
<ClCompile Include="..\..\xbmc\music\dialogs\GUIDialogMusicInfo.cpp">
<Filter>music\dialogs</Filter>
</ClCompile>
@@ -2303,9 +2300,6 @@
<ClCompile Include="..\..\xbmc\CueDocument.cpp">
<Filter>utils</Filter>
</ClCompile>
- <ClCompile Include="..\..\xbmc\DateTime.cpp">
- <Filter>utils</Filter>
- </ClCompile>
<ClCompile Include="..\..\xbmc\DynamicDll.cpp">
<Filter>utils</Filter>
</ClCompile>
@@ -2457,6 +2451,9 @@
<ClCompile Include="..\..\xbmc\interfaces\json-rpc\JSONServiceDescription.cpp">
<Filter>interfaces\json-rpc</Filter>
</ClCompile>
+ <ClCompile Include="..\..\xbmc\XBDateTime.cpp">
+ <Filter>utils</Filter>
+ </ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\xbmc\win32\pch.h">
@@ -3967,9 +3964,6 @@
<ClInclude Include="..\..\xbmc\interfaces\python\XBPython.h">
<Filter>interfaces\python</Filter>
</ClInclude>
- <ClInclude Include="..\..\xbmc\interfaces\python\XBPythonDll.h">
- <Filter>interfaces\python</Filter>
- </ClInclude>
<ClInclude Include="..\..\xbmc\interfaces\python\XBPyThread.h">
<Filter>interfaces\python</Filter>
</ClInclude>
@@ -4744,9 +4738,6 @@
<ClInclude Include="..\..\xbmc\CueDocument.h">
<Filter>utils</Filter>
</ClInclude>
- <ClInclude Include="..\..\xbmc\DateTime.h">
- <Filter>utils</Filter>
- </ClInclude>
<ClInclude Include="..\..\xbmc\DynamicDll.h">
<Filter>utils</Filter>
</ClInclude>
@@ -4915,6 +4906,12 @@
<ClInclude Include="..\..\xbmc\interfaces\json-rpc\ServiceDescription.h">
<Filter>interfaces\json-rpc</Filter>
</ClInclude>
+ <ClInclude Include="..\..\xbmc\interfaces\python\XBPythonDll.h">
+ <Filter>interfaces\python</Filter>
+ </ClInclude>
+ <ClInclude Include="..\..\xbmc\XBDateTime.h">
+ <Filter>utils</Filter>
+ </ClInclude>
</ItemGroup>
<ItemGroup>
<None Include="..\..\xbmc\win32\XBMC.ico">
diff --git a/tools/osx/osx-depends/xbmc/Makefile b/tools/osx/osx-depends/xbmc/Makefile
index 0e31ec2433..e8d5c7f84b 100644
--- a/tools/osx/osx-depends/xbmc/Makefile
+++ b/tools/osx/osx-depends/xbmc/Makefile
@@ -7,7 +7,8 @@ SOURCE=../../../../
# configuration settings
CONFIGURE=./configure --prefix=$(PREFIX) --host=$(HOST) \
--enable-external-python \
- PKG_CONFIG_PATH=$(PREFIX)/lib/pkgconfig
+ PKG_CONFIG_PATH=$(PREFIX)/lib/pkgconfig \
+ PYTHON=$(PREFIX)/bin/python
all: configure
diff --git a/xbmc/FileItem.h b/xbmc/FileItem.h
index 78c142cb52..0015b60734 100644
--- a/xbmc/FileItem.h
+++ b/xbmc/FileItem.h
@@ -28,7 +28,7 @@
#include "guilib/GUIListItem.h"
#include "utils/Archive.h"
#include "utils/ISerializable.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "SortFileItem.h"
#include "utils/LabelFormatter.h"
#include "GUIPassword.h"
diff --git a/xbmc/GUIInfoManager.h b/xbmc/GUIInfoManager.h
index 632b3347f9..250071b744 100644
--- a/xbmc/GUIInfoManager.h
+++ b/xbmc/GUIInfoManager.h
@@ -31,7 +31,7 @@
#include "threads/CriticalSection.h"
#include "guilib/IMsgTargetCallback.h"
#include "inttypes.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include <list>
#include <map>
diff --git a/xbmc/Makefile.in b/xbmc/Makefile.in
index 83dfe889e1..e73035d807 100644
--- a/xbmc/Makefile.in
+++ b/xbmc/Makefile.in
@@ -4,7 +4,6 @@ SRCS=Application.cpp \
AutoSwitch.cpp \
BackgroundInfoLoader.cpp \
CueDocument.cpp \
- DateTime.cpp \
DynamicDll.cpp \
Favourites.cpp \
FileItem.cpp \
@@ -31,6 +30,7 @@ SRCS=Application.cpp \
Util.cpp \
ViewDatabase.cpp \
XBApplicationEx.cpp \
+ XBDateTime.cpp \
xbmc.cpp \
LIB=xbmc.a
diff --git a/xbmc/TextureDatabase.cpp b/xbmc/TextureDatabase.cpp
index a9fc7a4278..59750b69dc 100644
--- a/xbmc/TextureDatabase.cpp
+++ b/xbmc/TextureDatabase.cpp
@@ -22,7 +22,7 @@
#include "TextureDatabase.h"
#include "utils/log.h"
#include "utils/Crc32.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "dbwrappers/dataset.h"
CTextureDatabase::CTextureDatabase()
diff --git a/xbmc/DateTime.cpp b/xbmc/XBDateTime.cpp
index 3ebce6c51c..53d467d4a7 100644
--- a/xbmc/DateTime.cpp
+++ b/xbmc/XBDateTime.cpp
@@ -19,7 +19,7 @@
*
*/
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "LangInfo.h"
#include "guilib/LocalizeStrings.h"
diff --git a/xbmc/DateTime.h b/xbmc/XBDateTime.h
index fbc67cf61e..fbc67cf61e 100644
--- a/xbmc/DateTime.h
+++ b/xbmc/XBDateTime.h
diff --git a/xbmc/addons/AddonDatabase.cpp b/xbmc/addons/AddonDatabase.cpp
index db01e09090..7c4e217407 100644
--- a/xbmc/addons/AddonDatabase.cpp
+++ b/xbmc/addons/AddonDatabase.cpp
@@ -22,7 +22,7 @@
#include "AddonDatabase.h"
#include "addons/AddonManager.h"
#include "utils/log.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "addons/Service.h"
#include "dbwrappers/dataset.h"
diff --git a/xbmc/addons/Repository.h b/xbmc/addons/Repository.h
index 7c88ea4411..ca0775da5e 100644
--- a/xbmc/addons/Repository.h
+++ b/xbmc/addons/Repository.h
@@ -22,7 +22,7 @@
#include "Addon.h"
#include "AddonManager.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "URL.h"
#include "utils/Job.h"
#include "threads/CriticalSection.h"
diff --git a/xbmc/addons/Scraper.h b/xbmc/addons/Scraper.h
index 7afc7d8474..d099ef4f5d 100644
--- a/xbmc/addons/Scraper.h
+++ b/xbmc/addons/Scraper.h
@@ -20,7 +20,7 @@
*
*/
#include "addons/Addon.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "utils/ScraperParser.h"
typedef enum
diff --git a/xbmc/dialogs/GUIDialogSeekBar.h b/xbmc/dialogs/GUIDialogSeekBar.h
index 2f7b77b57c..60ff5e28ec 100644
--- a/xbmc/dialogs/GUIDialogSeekBar.h
+++ b/xbmc/dialogs/GUIDialogSeekBar.h
@@ -22,7 +22,7 @@
*/
#include "guilib/GUIDialog.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
class CGUIDialogSeekBar : public CGUIDialog
{
diff --git a/xbmc/filesystem/MythDirectory.h b/xbmc/filesystem/MythDirectory.h
index ba8c409eb1..b942662a72 100644
--- a/xbmc/filesystem/MythDirectory.h
+++ b/xbmc/filesystem/MythDirectory.h
@@ -22,7 +22,7 @@
#include "IDirectory.h"
#include "MythSession.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
namespace XFILE
{
diff --git a/xbmc/filesystem/MythFile.cpp b/xbmc/filesystem/MythFile.cpp
index 8c0b9af1a8..97cea3335b 100644
--- a/xbmc/filesystem/MythFile.cpp
+++ b/xbmc/filesystem/MythFile.cpp
@@ -20,7 +20,7 @@
*/
#include "MythFile.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "FileItem.h"
#include "utils/URIUtils.h"
#include "DllLibCMyth.h"
diff --git a/xbmc/filesystem/MythFile.h b/xbmc/filesystem/MythFile.h
index 908f3598c2..c703c8ae7e 100644
--- a/xbmc/filesystem/MythFile.h
+++ b/xbmc/filesystem/MythFile.h
@@ -23,7 +23,7 @@
#include "IFile.h"
#include "ILiveTV.h"
#include "MythSession.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "video/VideoInfoTag.h"
#include <queue>
diff --git a/xbmc/filesystem/MythSession.cpp b/xbmc/filesystem/MythSession.cpp
index d61259d12e..17cc5ee5a4 100644
--- a/xbmc/filesystem/MythSession.cpp
+++ b/xbmc/filesystem/MythSession.cpp
@@ -23,7 +23,7 @@
#include "MythSession.h"
#include "video/VideoInfoTag.h"
#include "settings/AdvancedSettings.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "FileItem.h"
#include "URL.h"
#include "utils/URIUtils.h"
diff --git a/xbmc/guilib/GUIEditControl.cpp b/xbmc/guilib/GUIEditControl.cpp
index 23112b8c5d..21d2005d21 100644
--- a/xbmc/guilib/GUIEditControl.cpp
+++ b/xbmc/guilib/GUIEditControl.cpp
@@ -25,7 +25,7 @@
#include "dialogs/GUIDialogKeyboard.h"
#include "dialogs/GUIDialogNumeric.h"
#include "LocalizeStrings.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "utils/md5.h"
#ifdef __APPLE__
diff --git a/xbmc/interfaces/python/Makefile b/xbmc/interfaces/python/Makefile
deleted file mode 100644
index 11424fc560..0000000000
--- a/xbmc/interfaces/python/Makefile
+++ /dev/null
@@ -1,9 +0,0 @@
-SRCS=XBPython.cpp \
- XBPythonDll.cpp \
- XBPythonDllFuncs.S \
- XBPyThread.cpp \
-
-LIB=python.a
-
-include ../../../Makefile.include
--include $(patsubst %.cpp,%.P,$(patsubst %.c,%.P,$(patsubst %.S,,$(SRCS))))
diff --git a/xbmc/interfaces/python/Makefile.in b/xbmc/interfaces/python/Makefile.in
new file mode 100644
index 0000000000..b9fd7056d5
--- /dev/null
+++ b/xbmc/interfaces/python/Makefile.in
@@ -0,0 +1,14 @@
+SRCS=XBPython.cpp \
+ XBPyThread.cpp
+
+ifneq (@USE_EXTERNAL_PYTHON@,1)
+SRCS+=XBPythonDllFuncs.S \
+ XBPythonDll.cpp
+endif
+
+LIB=python.a
+
+INCLUDES+= @PYTHON_CPPFLAGS@
+
+include @abs_top_srcdir@/Makefile.include
+-include $(patsubst %.cpp,%.P,$(patsubst %.c,%.P,$(pathsubst %.S,,$(SRCS))))
diff --git a/xbmc/interfaces/python/XBPyThread.cpp b/xbmc/interfaces/python/XBPyThread.cpp
index 377155ec87..944d55d939 100644
--- a/xbmc/interfaces/python/XBPyThread.cpp
+++ b/xbmc/interfaces/python/XBPyThread.cpp
@@ -19,25 +19,15 @@
*
*/
+#if (defined HAVE_CONFIG_H) && (!defined WIN32)
+ #include "config.h"
+#endif
+
// python.h should always be included first before any other includes
+#include <Python.h>
+#include <osdefs.h>
+
#include "system.h"
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #include <python2.6/osdefs.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #include <python2.5/osdefs.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #include <python2.4/osdefs.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
- #include "python/Include/osdefs.h"
-#endif
#include "XBPythonDll.h"
#include "filesystem/SpecialProtocol.h"
#include "guilib/GUIWindowManager.h"
@@ -180,7 +170,7 @@ void XBPyThread::Process()
{
// we want to use sys.path so it includes site-packages
// if this fails, default to using Py_GetPath
- PyObject *sysMod(PyImport_ImportModule("sys")); // must call Py_DECREF when finished
+ PyObject *sysMod(PyImport_ImportModule((char*)"sys")); // must call Py_DECREF when finished
PyObject *sysModDict(PyModule_GetDict(sysMod)); // borrowed ref, no need to delete
PyObject *pathObj(PyDict_GetItemString(sysModDict, "path")); // borrowed ref, no need to delete
@@ -413,14 +403,14 @@ void XBPyThread::stop()
if (m_threadState)
{
PyEval_AcquireLock();
- PyThreadState* old = PyThreadState_Swap(m_threadState);
+ PyThreadState* old = PyThreadState_Swap((PyThreadState*)m_threadState);
PyObject *m;
m = PyImport_AddModule((char*)"xbmc");
if(!m || PyObject_SetAttrString(m, (char*)"abortRequested", PyBool_FromLong(1)))
CLog::Log(LOGERROR, "XBPyThread::stop - failed to set abortRequested");
- for(PyThreadState* state = m_threadState->interp->tstate_head; state; state = state->next)
+ for(PyThreadState* state = ((PyThreadState*)m_threadState)->interp->tstate_head; state; state = state->next)
{
Py_XDECREF(state->async_exc);
state->async_exc = PyExc_SystemExit;
diff --git a/xbmc/interfaces/python/XBPyThread.h b/xbmc/interfaces/python/XBPyThread.h
index 489aefb6cd..2ffe1504c8 100644
--- a/xbmc/interfaces/python/XBPyThread.h
+++ b/xbmc/interfaces/python/XBPyThread.h
@@ -22,22 +22,6 @@
#ifndef XBPYTHREAD_H_
#define XBPYTHREAD_H_
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
#include "threads/Thread.h"
class XBPython;
@@ -54,8 +38,8 @@ public:
void stop();
protected:
- XBPython *m_pExecuter;
- PyThreadState *m_threadState;
+ XBPython *m_pExecuter;
+ void *m_threadState;
char m_type;
char *m_source;
diff --git a/xbmc/interfaces/python/XBPython.cpp b/xbmc/interfaces/python/XBPython.cpp
index f4e02aab6d..0a0e679bb7 100644
--- a/xbmc/interfaces/python/XBPython.cpp
+++ b/xbmc/interfaces/python/XBPython.cpp
@@ -19,23 +19,14 @@
*
*/
-// python.h should always be included first before any other includes
#if (defined HAVE_CONFIG_H) && (!defined WIN32)
#include "config.h"
#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+
+// python.h should always be included first before any other includes
+#include <Python.h>
+
+#include "system.h"
#include "cores/DllLoader/DllLoaderContainer.h"
#include "GUIPassword.h"
@@ -363,6 +354,7 @@ void XBPython::Initialize()
m_iDllScriptCounter++;
if (!m_bInitialized)
{
+#if (!(defined _LINUX && defined USE_EXTERNAL_PYTHON))
m_pDll = DllLoaderContainer::LoadModule(PYTHON_DLL, NULL, true);
if (!m_pDll || !python_load_dll(*m_pDll))
@@ -371,6 +363,7 @@ void XBPython::Initialize()
Finalize();
return;
}
+#endif
// first we check if all necessary files are installed
#ifndef _LINUX
@@ -476,7 +469,7 @@ void XBPython::Finalize()
CLog::Log(LOGINFO, "Python, unloading python24.dll because no scripts are running anymore");
PyEval_AcquireLock();
- PyThreadState_Swap(m_mainThreadState);
+ PyThreadState_Swap((PyThreadState*)m_mainThreadState);
Py_Finalize();
PyEval_ReleaseLock();
@@ -647,7 +640,7 @@ void XBPython::stopScript(int id)
}
}
-PyThreadState *XBPython::getMainThreadState()
+void* XBPython::getMainThreadState()
{
CSingleLock lock(m_critSection);
return m_mainThreadState;
diff --git a/xbmc/interfaces/python/XBPython.h b/xbmc/interfaces/python/XBPython.h
index 520a1e4381..81b96352e6 100644
--- a/xbmc/interfaces/python/XBPython.h
+++ b/xbmc/interfaces/python/XBPython.h
@@ -98,7 +98,7 @@ public:
// returns -1 if no scripts exist with specified filename
int getScriptId(const CStdString &strFile);
- PyThreadState *getMainThreadState();
+ void* getMainThreadState();
bool m_bLogin;
CCriticalSection m_critSection;
@@ -106,7 +106,7 @@ private:
bool FileExist(const char* strFile);
int m_nextid;
- PyThreadState* m_mainThreadState;
+ void* m_mainThreadState;
ThreadIdentifier m_ThreadId;
bool m_bInitialized;
HANDLE m_hEvent;
diff --git a/xbmc/interfaces/python/XBPythonDll.cpp b/xbmc/interfaces/python/XBPythonDll.cpp
index c4c0563670..38f5c8be32 100644
--- a/xbmc/interfaces/python/XBPythonDll.cpp
+++ b/xbmc/interfaces/python/XBPythonDll.cpp
@@ -19,19 +19,9 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
+#include "system.h"
#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/pyconfig.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/pyconfig.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/pyconfig.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
+#include <Python.h>
#else
#include "python/Include/pyconfig.h"
#endif
diff --git a/xbmc/interfaces/python/XBPythonDll.h b/xbmc/interfaces/python/XBPythonDll.h
index 7d2e816f8f..5997d94fbe 100644
--- a/xbmc/interfaces/python/XBPythonDll.h
+++ b/xbmc/interfaces/python/XBPythonDll.h
@@ -24,6 +24,8 @@
#if (defined HAVE_CONFIG_H) && (!defined WIN32)
#include "config.h"
#endif
+
+#if (!defined USE_EXTERNAL_PYTHON)
#define DATA_OBJECT(data) unsigned long pointer_##data;
#define _Py_NoneStruct (*((PyObject*)pointer__Py_NoneStruct))
@@ -96,3 +98,4 @@ class LibraryLoader;
}
#endif
+#endif
diff --git a/xbmc/interfaces/python/XBPythonDllFuncs.S b/xbmc/interfaces/python/XBPythonDllFuncs.S
index 44186acc12..33cc8ff6d2 100644
--- a/xbmc/interfaces/python/XBPythonDllFuncs.S
+++ b/xbmc/interfaces/python/XBPythonDllFuncs.S
@@ -2,15 +2,7 @@
#include "config.h"
#endif
#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/pyconfig.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/pyconfig.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/pyconfig.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
+#include <pyconfig.h>
#else
#include "python/Include/pyconfig.h"
#endif
diff --git a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.cpp b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.cpp
index 666ecd61df..46a254ee0d 100644
--- a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.cpp
@@ -19,8 +19,8 @@
*
*/
-#include "GUIPythonWindow.h"
#include "pyutil.h"
+#include "GUIPythonWindow.h"
#include "window.h"
#include "control.h"
#include "action.h"
@@ -31,7 +31,7 @@
using namespace PYXBMC;
-PyXBMCAction::PyXBMCAction(PyObject*& callback)
+PyXBMCAction::PyXBMCAction(void*& callback)
: param(0), pCallbackWindow(NULL), pObject(NULL), controlId(0), type(0)
{
// this is ugly, but we can't grab python lock
@@ -43,15 +43,16 @@ PyXBMCAction::PyXBMCAction(PyObject*& callback)
// callback can become null while we are trying
// to grab python lock above, so anything using
// this should allow that situation
- pCallbackWindow = callback;
- Py_XINCREF(callback);
+ void* tmp = callback; // copy the referenced value
+ pCallbackWindow = (PyObject*)tmp; // assign internally
+ Py_XINCREF((PyObject*)callback);
PyEval_ReleaseLock();
}
PyXBMCAction::~PyXBMCAction() {
- Py_XDECREF(pObject);
- Py_XDECREF(pCallbackWindow);
+ Py_XDECREF((PyObject*)pObject);
+ Py_XDECREF((PyObject*)pCallbackWindow);
}
CGUIPythonWindow::CGUIPythonWindow(int id)
@@ -85,7 +86,7 @@ bool CGUIPythonWindow::OnAction(const CAction &action)
inf->pObject = Action_FromAction(action);
// aquire lock?
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnAction, inf);
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnAction, inf);
PulseActionEvent();
}
return ret;
@@ -122,8 +123,8 @@ bool CGUIPythonWindow::OnMessage(CGUIMessage& message)
Control* pControl = *it;
if (pControl->iControlId == iControl)
{
- inf->pObject = (PyObject*)pControl;
- Py_INCREF(inf->pObject);
+ inf->pObject = pControl;
+ Py_INCREF((PyObject*)inf->pObject);
break;
}
++it;
@@ -132,12 +133,12 @@ bool CGUIPythonWindow::OnMessage(CGUIMessage& message)
if (inf->pObject)
{
// currently we only accept messages from a button or controllist with a select action
- if ((ControlList_CheckExact(inf->pObject) && (message.GetParam1() == ACTION_SELECT_ITEM || message.GetParam1() == ACTION_MOUSE_LEFT_CLICK)) ||
- ControlButton_CheckExact(inf->pObject) || ControlRadioButton_CheckExact(inf->pObject) ||
- ControlCheckMark_CheckExact(inf->pObject))
+ if ((ControlList_CheckExact((PyObject*)inf->pObject) && (message.GetParam1() == ACTION_SELECT_ITEM || message.GetParam1() == ACTION_MOUSE_LEFT_CLICK)) ||
+ ControlButton_CheckExact((PyObject*)inf->pObject) || ControlRadioButton_CheckExact((PyObject*)inf->pObject) ||
+ ControlCheckMark_CheckExact((PyObject*)inf->pObject))
{
// aquire lock?
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnControl, inf);
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnControl, inf);
PulseActionEvent();
// return true here as we are handling the event
@@ -155,7 +156,7 @@ bool CGUIPythonWindow::OnMessage(CGUIMessage& message)
return CGUIWindow::OnMessage(message);
}
-void CGUIPythonWindow::SetCallbackWindow(PyThreadState *state, PyObject *object)
+void CGUIPythonWindow::SetCallbackWindow(void *state, void *object)
{
pCallbackWindow = object;
m_threadState = state;
@@ -236,7 +237,7 @@ int Py_XBMC_Event_OnControl(void* arg)
if (action->pCallbackWindow)
{
PyXBMCAction* action = (PyXBMCAction*)arg;
- PyObject *ret = PyObject_CallMethod(action->pCallbackWindow, (char*)"onControl", (char*)"(O)", action->pObject);
+ PyObject *ret = PyObject_CallMethod((PyObject*)action->pCallbackWindow, (char*)"onControl", (char*)"(O)", (PyObject*)action->pObject);
if (ret) {
Py_DECREF(ret);
}
@@ -258,7 +259,7 @@ int Py_XBMC_Event_OnAction(void* arg)
{
Action *pAction= (Action *)action->pObject;
- PyObject *ret = PyObject_CallMethod(action->pCallbackWindow, (char*)"onAction", (char*)"(O)", pAction);
+ PyObject *ret = PyObject_CallMethod((PyObject*)action->pCallbackWindow, (char*)"onAction", (char*)"(O)", (PyObject*)pAction);
if (ret) {
Py_DECREF(ret);
}
diff --git a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.h b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.h
index 725105401a..2146d90773 100644
--- a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.h
+++ b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindow.h
@@ -22,35 +22,19 @@
*/
#include "guilib/GUIWindow.h"
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
class PyXBMCAction
{
public:
int param;
- PyObject* pCallbackWindow;
- PyObject* pObject;
+ void* pCallbackWindow;
+ void* pObject;
int controlId; // for XML window
#if defined(_LINUX) || defined(_WIN32)
int type; // 0=Action, 1=Control;
#endif
- PyXBMCAction(PyObject*& callback);
+ PyXBMCAction(void*& callback);
virtual ~PyXBMCAction() ;
};
@@ -64,11 +48,11 @@ public:
virtual ~CGUIPythonWindow(void);
virtual bool OnMessage(CGUIMessage& message);
virtual bool OnAction(const CAction &action);
- void SetCallbackWindow(PyThreadState *state, PyObject *object);
+ void SetCallbackWindow(void* state, void *object);
void WaitForActionEvent(unsigned int timeout);
void PulseActionEvent();
protected:
- PyObject* pCallbackWindow;
- PyThreadState* m_threadState;
+ void* pCallbackWindow;
+ void* m_threadState;
HANDLE m_actionEvent;
};
diff --git a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.cpp b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.cpp
index c54ea67358..f932810cc7 100644
--- a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.cpp
@@ -19,8 +19,8 @@
*
*/
-#include "GUIPythonWindowXML.h"
#include "pyutil.h"
+#include "GUIPythonWindowXML.h"
#include "window.h"
#include "control.h"
#include "action.h"
@@ -75,7 +75,7 @@ bool CGUIPythonWindowXML::OnAction(const CAction &action)
inf->pObject = Action_FromAction(action);
// aquire lock?
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnAction, inf);
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnAction, inf);
PulseActionEvent();
}
return ret;
@@ -115,7 +115,7 @@ bool CGUIPythonWindowXML::OnMessage(CGUIMessage& message)
CGUIMediaWindow::OnMessage(message);
if(pCallbackWindow)
{
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnInit, new PyXBMCAction(pCallbackWindow));
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnInit, new PyXBMCAction(pCallbackWindow));
PulseActionEvent();
}
return true;
@@ -136,7 +136,7 @@ bool CGUIPythonWindowXML::OnMessage(CGUIMessage& message)
PyXBMCAction* inf = new PyXBMCAction(pCallbackWindow);
inf->controlId = iControl;
// aquire lock?
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnFocus, inf);
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnFocus, inf);
PulseActionEvent();
}
}
@@ -179,7 +179,7 @@ bool CGUIPythonWindowXML::OnMessage(CGUIMessage& message)
PyXBMCAction* inf = new PyXBMCAction(pCallbackWindow);
inf->controlId = iControl;
// aquire lock?
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnClick, inf);
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnClick, inf);
PulseActionEvent();
return true;
}
@@ -189,7 +189,7 @@ bool CGUIPythonWindowXML::OnMessage(CGUIMessage& message)
inf->pObject = Action_FromAction(CAction(ACTION_CONTEXT_MENU));
// aquire lock?
- PyXBMC_AddPendingCall(m_threadState, Py_XBMC_Event_OnAction, inf);
+ PyXBMC_AddPendingCall((PyThreadState*)m_threadState, Py_XBMC_Event_OnAction, inf);
PulseActionEvent();
return true;
}
@@ -360,7 +360,7 @@ int Py_XBMC_Event_OnClick(void* arg)
PyXBMCAction* action = (PyXBMCAction*)arg;
if (action->pCallbackWindow)
{
- PyObject *ret = PyObject_CallMethod(action->pCallbackWindow, (char*)"onClick", (char*)"(i)", action->controlId);
+ PyObject *ret = PyObject_CallMethod((PyObject*)action->pCallbackWindow, (char*)"onClick", (char*)"(i)", action->controlId);
if (ret)
{
Py_DECREF(ret);
@@ -378,7 +378,7 @@ int Py_XBMC_Event_OnFocus(void* arg)
PyXBMCAction* action = (PyXBMCAction*)arg;
if (action->pCallbackWindow)
{
- PyObject *ret = PyObject_CallMethod(action->pCallbackWindow, (char*)"onFocus", (char*)"(i)", action->controlId);
+ PyObject *ret = PyObject_CallMethod((PyObject*)action->pCallbackWindow, (char*)"onFocus", (char*)"(i)", action->controlId);
if (ret)
{
Py_DECREF(ret);
@@ -396,7 +396,7 @@ int Py_XBMC_Event_OnInit(void* arg)
PyXBMCAction* action = (PyXBMCAction*)arg;
if (action->pCallbackWindow)
{
- PyObject *ret = PyObject_CallMethod(action->pCallbackWindow, (char*)"onInit", (char*)"()"); //, (char*)"O", &self);
+ PyObject *ret = PyObject_CallMethod((PyObject*)action->pCallbackWindow, (char*)"onInit", (char*)"()"); //, (char*)"O", &self);
if (ret)
{
Py_XDECREF(ret);
@@ -406,7 +406,7 @@ int Py_XBMC_Event_OnInit(void* arg)
return 0;
}
-void CGUIPythonWindowXML::SetCallbackWindow(PyThreadState *state, PyObject *object)
+void CGUIPythonWindowXML::SetCallbackWindow(void *state, void *object)
{
pCallbackWindow = object;
m_threadState = state;
diff --git a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.h b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.h
index 3e26854d25..4b17b1fc61 100644
--- a/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.h
+++ b/xbmc/interfaces/python/xbmcmodule/GUIPythonWindowXML.h
@@ -47,7 +47,7 @@ public:
int GetListSize();
int GetCurrentListPosition();
void SetCurrentListPosition(int item);
- void SetCallbackWindow(PyThreadState* state, PyObject *object);
+ void SetCallbackWindow(void* state, void* object);
virtual bool OnClick(int iItem);
void SetProperty(const CStdString &strProperty, const CStdString &strValue);
@@ -58,8 +58,8 @@ protected:
void ClearScriptStrings();
virtual bool Update(const CStdString &strPath);
void SetupShares();
- PyObject* pCallbackWindow;
- PyThreadState* m_threadState;
+ void* pCallbackWindow;
+ void* m_threadState;
HANDLE m_actionEvent;
bool m_bRunning;
CStdString m_scriptPath;
diff --git a/xbmc/interfaces/python/xbmcmodule/Makefile b/xbmc/interfaces/python/xbmcmodule/Makefile.in
index 388a05bce4..be956f34d0 100644
--- a/xbmc/interfaces/python/xbmcmodule/Makefile
+++ b/xbmc/interfaces/python/xbmcmodule/Makefile.in
@@ -37,5 +37,7 @@ SRCS=action.cpp \
LIB=xbmcmodule.a
-include ../../../../Makefile.include
+INCLUDES+= @PYTHON_CPPFLAGS@
+
+include @abs_top_srcdir@/Makefile.include
-include $(patsubst %.cpp,%.P,$(patsubst %.c,%.P,$(SRCS)))
diff --git a/xbmc/interfaces/python/xbmcmodule/PythonAddon.h b/xbmc/interfaces/python/xbmcmodule/PythonAddon.h
index 3a336d9da4..83237dc585 100644
--- a/xbmc/interfaces/python/xbmcmodule/PythonAddon.h
+++ b/xbmc/interfaces/python/xbmcmodule/PythonAddon.h
@@ -21,22 +21,7 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
#include "addons/IAddon.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/PythonPlayer.h b/xbmc/interfaces/python/xbmcmodule/PythonPlayer.h
index cac9e19971..17eb7e12a5 100644
--- a/xbmc/interfaces/python/xbmcmodule/PythonPlayer.h
+++ b/xbmc/interfaces/python/xbmcmodule/PythonPlayer.h
@@ -21,22 +21,7 @@
#pragma once
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
#include "cores/IPlayer.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/action.h b/xbmc/interfaces/python/xbmcmodule/action.h
index 6a583e6ff3..4b4346d751 100644
--- a/xbmc/interfaces/python/xbmcmodule/action.h
+++ b/xbmc/interfaces/python/xbmcmodule/action.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "listitem.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/control.h b/xbmc/interfaces/python/xbmcmodule/control.h
index 2dbb84e428..3877eb7bfa 100644
--- a/xbmc/interfaces/python/xbmcmodule/control.h
+++ b/xbmc/interfaces/python/xbmcmodule/control.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "listitem.h"
#include "guilib/GUIColorManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlbutton.cpp b/xbmc/interfaces/python/xbmcmodule/controlbutton.cpp
index b0bc25db2b..90bb39a5cb 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlbutton.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlbutton.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUIButtonControl.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlcheckmark.cpp b/xbmc/interfaces/python/xbmcmodule/controlcheckmark.cpp
index e74e6648ee..8aa66fc336 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlcheckmark.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlcheckmark.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUICheckMarkControl.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlfadelabel.cpp b/xbmc/interfaces/python/xbmcmodule/controlfadelabel.cpp
index 202a583026..e014b0422b 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlfadelabel.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlfadelabel.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUIFadeLabelControl.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlgroup.cpp b/xbmc/interfaces/python/xbmcmodule/controlgroup.cpp
index 21e7609bf5..a89204ec64 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlgroup.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlgroup.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "guilib/GUIControlGroup.h"
#include "guilib/GUIFontManager.h"
#include "control.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlimage.cpp b/xbmc/interfaces/python/xbmcmodule/controlimage.cpp
index 65ad8bccf6..c70a9f8e64 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlimage.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlimage.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUIImage.h"
#include "control.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controllabel.cpp b/xbmc/interfaces/python/xbmcmodule/controllabel.cpp
index 34e645bab8..93713b34f8 100644
--- a/xbmc/interfaces/python/xbmcmodule/controllabel.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controllabel.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUILabelControl.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controllist.cpp b/xbmc/interfaces/python/xbmcmodule/controllist.cpp
index 658539200d..576b8d7c90 100644
--- a/xbmc/interfaces/python/xbmcmodule/controllist.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controllist.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUIListContainer.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlprogress.cpp b/xbmc/interfaces/python/xbmcmodule/controlprogress.cpp
index 9ffaedd775..39f4cf814f 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlprogress.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlprogress.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "guilib/GUIProgressControl.h"
#include "control.h"
#include "pyutil.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlradiobutton.cpp b/xbmc/interfaces/python/xbmcmodule/controlradiobutton.cpp
index 32251b9dcf..82e4827abc 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlradiobutton.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlradiobutton.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUIRadioButtonControl.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlslider.cpp b/xbmc/interfaces/python/xbmcmodule/controlslider.cpp
index 55d67ac0ed..0af6645ec7 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlslider.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlslider.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "guilib/GUISliderControl.h"
#include "control.h"
#include "pyutil.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controlspin.cpp b/xbmc/interfaces/python/xbmcmodule/controlspin.cpp
index f8e72f412d..ac076ac338 100644
--- a/xbmc/interfaces/python/xbmcmodule/controlspin.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controlspin.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUISpinControl.h"
#include "control.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/controltextbox.cpp b/xbmc/interfaces/python/xbmcmodule/controltextbox.cpp
index dfce4ee1de..9f00225d9e 100644
--- a/xbmc/interfaces/python/xbmcmodule/controltextbox.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/controltextbox.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "guilib/GUITextBox.h"
#include "guilib/GUIFontManager.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/dialog.cpp b/xbmc/interfaces/python/xbmcmodule/dialog.cpp
index 42aa144941..aeefa42db2 100644
--- a/xbmc/interfaces/python/xbmcmodule/dialog.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/dialog.cpp
@@ -19,23 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
#include "dialog.h"
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+
#include "../XBPythonDll.h"
#include "Application.h"
#include "settings/Settings.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/dialog.h b/xbmc/interfaces/python/xbmcmodule/dialog.h
index b006f0b589..93d0a9eb68 100644
--- a/xbmc/interfaces/python/xbmcmodule/dialog.h
+++ b/xbmc/interfaces/python/xbmcmodule/dialog.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "window.h"
#pragma once
diff --git a/xbmc/interfaces/python/xbmcmodule/infotagmusic.h b/xbmc/interfaces/python/xbmcmodule/infotagmusic.h
index 8106997f5f..448562bf2c 100644
--- a/xbmc/interfaces/python/xbmcmodule/infotagmusic.h
+++ b/xbmc/interfaces/python/xbmcmodule/infotagmusic.h
@@ -19,22 +19,7 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
#include "music/tags/MusicInfoTag.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/infotagvideo.h b/xbmc/interfaces/python/xbmcmodule/infotagvideo.h
index 0dd65239da..4fed3bd8bf 100644
--- a/xbmc/interfaces/python/xbmcmodule/infotagvideo.h
+++ b/xbmc/interfaces/python/xbmcmodule/infotagvideo.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "video/VideoInfoTag.h"
#pragma once
diff --git a/xbmc/interfaces/python/xbmcmodule/keyboard.h b/xbmc/interfaces/python/xbmcmodule/keyboard.h
index 2643e9011d..b9335dd8db 100644
--- a/xbmc/interfaces/python/xbmcmodule/keyboard.h
+++ b/xbmc/interfaces/python/xbmcmodule/keyboard.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include <string>
#pragma once
diff --git a/xbmc/interfaces/python/xbmcmodule/listitem.cpp b/xbmc/interfaces/python/xbmcmodule/listitem.cpp
index c68c8d692f..37cff5b1cd 100644
--- a/xbmc/interfaces/python/xbmcmodule/listitem.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/listitem.cpp
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "listitem.h"
#include "pyutil.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/listitem.h b/xbmc/interfaces/python/xbmcmodule/listitem.h
index 499d73481e..3ec788cbb5 100644
--- a/xbmc/interfaces/python/xbmcmodule/listitem.h
+++ b/xbmc/interfaces/python/xbmcmodule/listitem.h
@@ -21,22 +21,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "FileItem.h"
#define ListItem_Check(op) PyObject_TypeCheck(op, &ListItem_Type)
diff --git a/xbmc/interfaces/python/xbmcmodule/player.cpp b/xbmc/interfaces/python/xbmcmodule/player.cpp
index 54bf4e8c8d..1c8df78ae1 100644
--- a/xbmc/interfaces/python/xbmcmodule/player.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/player.cpp
@@ -19,12 +19,12 @@
*
*/
+#include "pyutil.h"
#include "Application.h"
#include "GUIInfoManager.h"
#include "PlayListPlayer.h"
#include "player.h"
#include "pyplaylist.h"
-#include "pyutil.h"
#include "infotagvideo.h"
#include "infotagmusic.h"
#include "listitem.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/player.h b/xbmc/interfaces/python/xbmcmodule/player.h
index 30acacf7fb..e994b5757f 100644
--- a/xbmc/interfaces/python/xbmcmodule/player.h
+++ b/xbmc/interfaces/python/xbmcmodule/player.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "PythonPlayer.h"
#include "cores/playercorefactory/PlayerCoreFactory.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/pyplaylist.cpp b/xbmc/interfaces/python/xbmcmodule/pyplaylist.cpp
index 04679b2462..253c1024da 100644
--- a/xbmc/interfaces/python/xbmcmodule/pyplaylist.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/pyplaylist.cpp
@@ -19,26 +19,14 @@
*
*/
-#include "system.h"
+#include <Python.h>
+
+#include "pyutil.h"
#include "PlayListPlayer.h"
#include "utils/URIUtils.h"
#include "pyplaylist.h"
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/structmember.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/structmember.h"
-#endif
#include "../XBPythonDll.h"
#include "playlists/PlayListFactory.h"
-#include "pyutil.h"
#include "listitem.h"
#include "playlists/PlayList.h"
#include "video/VideoInfoTag.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/pyplaylist.h b/xbmc/interfaces/python/xbmcmodule/pyplaylist.h
index 9128f5f0de..15c1d9b242 100644
--- a/xbmc/interfaces/python/xbmcmodule/pyplaylist.h
+++ b/xbmc/interfaces/python/xbmcmodule/pyplaylist.h
@@ -21,22 +21,7 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
#include "FileItem.h"
#define PlayList_Check(op) PyObject_TypeCheck(op, &PlayList_Type)
diff --git a/xbmc/interfaces/python/xbmcmodule/pyutil.h b/xbmc/interfaces/python/xbmcmodule/pyutil.h
index bca16b9e98..f5d456930f 100644
--- a/xbmc/interfaces/python/xbmcmodule/pyutil.h
+++ b/xbmc/interfaces/python/xbmcmodule/pyutil.h
@@ -19,25 +19,10 @@
*
*/
-#include "utils/StdString.h"
+#include <Python.h>
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
#include "../XBPythonDll.h"
+#include "utils/StdString.h"
#ifdef __cplusplus
extern "C" {
diff --git a/xbmc/interfaces/python/xbmcmodule/window.h b/xbmc/interfaces/python/xbmcmodule/window.h
index e355a6328a..a188b09d0e 100644
--- a/xbmc/interfaces/python/xbmcmodule/window.h
+++ b/xbmc/interfaces/python/xbmcmodule/window.h
@@ -19,22 +19,8 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "GUIPythonWindow.h"
#include "GUIPythonWindowXML.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/winxml.cpp b/xbmc/interfaces/python/xbmcmodule/winxml.cpp
index dd39f9f786..b05fb8f075 100644
--- a/xbmc/interfaces/python/xbmcmodule/winxml.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/winxml.cpp
@@ -19,21 +19,9 @@
*
*/
-#include "system.h"
+#include <Python.h>
+
#include "winxml.h"
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
#include "../XBPythonDll.h"
#include "pyutil.h"
#include "GUIPythonWindowXML.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/winxml.h b/xbmc/interfaces/python/xbmcmodule/winxml.h
index 2df67f8863..82e284ee51 100644
--- a/xbmc/interfaces/python/xbmcmodule/winxml.h
+++ b/xbmc/interfaces/python/xbmcmodule/winxml.h
@@ -19,22 +19,7 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
#include "window.h"
#pragma once
diff --git a/xbmc/interfaces/python/xbmcmodule/winxmldialog.cpp b/xbmc/interfaces/python/xbmcmodule/winxmldialog.cpp
index 3f665a17a8..aacb1455b6 100644
--- a/xbmc/interfaces/python/xbmcmodule/winxmldialog.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/winxmldialog.cpp
@@ -19,22 +19,11 @@
*
*/
-#include "system.h"
-#include "winxml.h"
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
+
+#include "winxml.h"
#include "pyutil.h"
#include "GUIPythonWindowXMLDialog.h"
#include "addons/Skin.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/xbmcaddonmodule.cpp b/xbmc/interfaces/python/xbmcmodule/xbmcaddonmodule.cpp
index c747cebbcb..512774c55f 100644
--- a/xbmc/interfaces/python/xbmcmodule/xbmcaddonmodule.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/xbmcaddonmodule.cpp
@@ -19,22 +19,7 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
#include "PythonAddon.h"
#include "pyutil.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/xbmcguimodule.cpp b/xbmc/interfaces/python/xbmcmodule/xbmcguimodule.cpp
index 1c139578e6..0b7ea7fa7b 100644
--- a/xbmc/interfaces/python/xbmcmodule/xbmcguimodule.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/xbmcguimodule.cpp
@@ -19,26 +19,9 @@
*
*/
-#if (defined HAVE_CONFIG_H) && (!defined WIN32)
- #include "config.h"
-#endif
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #include <python2.6/structmember.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #include <python2.5/structmember.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #include <python2.4/structmember.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
- #include "python/Include/structmember.h"
-#endif
+#include <Python.h>
+#include <structmember.h>
+
#include "../XBPythonDll.h"
#include "control.h"
#include "window.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/xbmcmodule.cpp b/xbmc/interfaces/python/xbmcmodule/xbmcmodule.cpp
index 9a1e239b3d..58ad3558d9 100644
--- a/xbmc/interfaces/python/xbmcmodule/xbmcmodule.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/xbmcmodule.cpp
@@ -19,20 +19,8 @@
*
*/
-#include "system.h"
-#if (defined USE_EXTERNAL_PYTHON)
- #if (defined HAVE_LIBPYTHON2_6)
- #include <python2.6/Python.h>
- #elif (defined HAVE_LIBPYTHON2_5)
- #include <python2.5/Python.h>
- #elif (defined HAVE_LIBPYTHON2_4)
- #include <python2.4/Python.h>
- #else
- #error "Could not determine version of Python to use."
- #endif
-#else
- #include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "player.h"
#include "pyplaylist.h"
diff --git a/xbmc/interfaces/python/xbmcmodule/xbmcplugin.cpp b/xbmc/interfaces/python/xbmcmodule/xbmcplugin.cpp
index d6a46f479e..f1e3d3576c 100644
--- a/xbmc/interfaces/python/xbmcmodule/xbmcplugin.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/xbmcplugin.cpp
@@ -19,13 +19,13 @@
*
*/
+// include for constants
+#include "pyutil.h"
+
#include "filesystem/PluginDirectory.h"
#include "listitem.h"
#include "FileItem.h"
-// include for constants
-#include "pyutil.h"
-
using namespace std;
using namespace XFILE;
using namespace ADDON;
diff --git a/xbmc/interfaces/python/xbmcmodule/xbmcvfsmodule.cpp b/xbmc/interfaces/python/xbmcmodule/xbmcvfsmodule.cpp
index 5b0f5de2f9..96e5dcb74f 100644
--- a/xbmc/interfaces/python/xbmcmodule/xbmcvfsmodule.cpp
+++ b/xbmc/interfaces/python/xbmcmodule/xbmcvfsmodule.cpp
@@ -19,20 +19,8 @@
*
*/
-#include "system.h"
-#if (defined USE_EXTERNAL_PYTHON)
-#if (defined HAVE_LIBPYTHON2_6)
-#include <python2.6/Python.h>
-#elif (defined HAVE_LIBPYTHON2_5)
-#include <python2.5/Python.h>
-#elif (defined HAVE_LIBPYTHON2_4)
-#include <python2.4/Python.h>
-#else
-#error "Could not determine version of Python to use."
-#endif
-#else
-#include "python/Include/Python.h"
-#endif
+#include <Python.h>
+
#include "../XBPythonDll.h"
#include "filesystem/File.h"
diff --git a/xbmc/network/WebServer.cpp b/xbmc/network/WebServer.cpp
index 1ee5d9e16c..48548d0b2a 100644
--- a/xbmc/network/WebServer.cpp
+++ b/xbmc/network/WebServer.cpp
@@ -29,7 +29,7 @@
#include "utils/log.h"
#include "utils/URIUtils.h"
#include "threads/SingleLock.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "addons/AddonManager.h"
#ifdef _WIN32
diff --git a/xbmc/pictures/PictureInfoTag.cpp b/xbmc/pictures/PictureInfoTag.cpp
index 96c1f4f020..e286d7ffa3 100644
--- a/xbmc/pictures/PictureInfoTag.cpp
+++ b/xbmc/pictures/PictureInfoTag.cpp
@@ -20,7 +20,7 @@
*/
#include "PictureInfoTag.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "Util.h"
#include "utils/Variant.h"
diff --git a/xbmc/playlists/SmartPlayList.cpp b/xbmc/playlists/SmartPlayList.cpp
index 0540566853..7ddf34a834 100644
--- a/xbmc/playlists/SmartPlayList.cpp
+++ b/xbmc/playlists/SmartPlayList.cpp
@@ -29,7 +29,7 @@
#include "utils/XMLUtils.h"
#include "video/VideoDatabase.h"
#include "Util.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "guilib/LocalizeStrings.h"
using namespace std;
diff --git a/xbmc/utils/StringUtils.h b/xbmc/utils/StringUtils.h
index c290a0f339..9de22b0082 100644
--- a/xbmc/utils/StringUtils.h
+++ b/xbmc/utils/StringUtils.h
@@ -32,7 +32,7 @@
#ifndef __STRINGUTILS_H_
#define __STRINGUTILS_H_
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "utils/StdString.h"
#include <vector>
#include <stdint.h>
diff --git a/xbmc/utils/TimeUtils.cpp b/xbmc/utils/TimeUtils.cpp
index 07b88fbaf7..5f721dce68 100644
--- a/xbmc/utils/TimeUtils.cpp
+++ b/xbmc/utils/TimeUtils.cpp
@@ -20,7 +20,7 @@
*/
#include "TimeUtils.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#ifdef __APPLE__
#if defined(__ppc__) || defined(__arm__)
diff --git a/xbmc/utils/Weather.cpp b/xbmc/utils/Weather.cpp
index d654213dfb..0f75b66df2 100644
--- a/xbmc/utils/Weather.cpp
+++ b/xbmc/utils/Weather.cpp
@@ -39,7 +39,7 @@
#include "GUIUserMessages.h"
#include "dialogs/GUIDialogProgress.h"
#include "dialogs/GUIDialogSelect.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "LangInfo.h"
#include "guilib/LocalizeStrings.h"
#include "filesystem/Directory.h"
diff --git a/xbmc/video/VideoInfoDownloader.h b/xbmc/video/VideoInfoDownloader.h
index 292887152f..b1d961092a 100644
--- a/xbmc/video/VideoInfoDownloader.h
+++ b/xbmc/video/VideoInfoDownloader.h
@@ -24,7 +24,7 @@
#include "threads/Thread.h"
#include "VideoInfoTag.h"
#include "addons/Scraper.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "filesystem/FileCurl.h"
// forward definitions
diff --git a/xbmc/video/VideoInfoScanner.h b/xbmc/video/VideoInfoScanner.h
index 19d4e725eb..9f16aff362 100644
--- a/xbmc/video/VideoInfoScanner.h
+++ b/xbmc/video/VideoInfoScanner.h
@@ -24,7 +24,7 @@
#include "addons/Scraper.h"
#include "NfoFile.h"
#include "VideoInfoDownloader.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
class CIMDB;
class CRegExp;
diff --git a/xbmc/video/windows/GUIWindowFullScreen.cpp b/xbmc/video/windows/GUIWindowFullScreen.cpp
index de31f144d2..f143641fad 100644
--- a/xbmc/video/windows/GUIWindowFullScreen.cpp
+++ b/xbmc/video/windows/GUIWindowFullScreen.cpp
@@ -48,7 +48,7 @@
#include "threads/SingleLock.h"
#include "utils/log.h"
#include "utils/TimeUtils.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "input/ButtonTranslator.h"
#include <stdio.h>
diff --git a/xbmc/win32/XBMC_PC.cpp b/xbmc/win32/XBMC_PC.cpp
index 192f9db3b9..4e98e120cc 100644
--- a/xbmc/win32/XBMC_PC.cpp
+++ b/xbmc/win32/XBMC_PC.cpp
@@ -24,7 +24,7 @@
#include "WIN32Util.h"
#include "shellapi.h"
#include "dbghelp.h"
-#include "DateTime.h"
+#include "XBDateTime.h"
#include "threads/Thread.h"
#include "Application.h"