python-sip: Check for python-dev prereq
authormb <mb@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sat, 23 Oct 2010 20:16:12 +0000 (20:16 +0000)
committermb <mb@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Sat, 23 Oct 2010 20:16:12 +0000 (20:16 +0000)
git-svn-id: svn://svn.openwrt.org/openwrt/packages@23597 3c298f89-4303-0410-b956-a3cf2f4a3e73

lang/python-sip/Makefile

index 6f50adf..3b9368e 100644 (file)
@@ -127,7 +127,16 @@ define Host/Install
                install
 endef
 
-#TODO check for host python-dev headers.
+define Require/python2-dev
+  [ -e /usr/include/Python.h ] || \
+  [ -e /usr/include/python/Python.h ] || \
+  [ -e /usr/include/python2.5/Python.h ] || \
+  [ -e /usr/include/python2.6/Python.h ]
+endef
+
+$(eval $(call Require,python2-dev, \
+       Please install Python 2.x headers (python-dev) \
+))
 
 $(eval $(call RequireCommand,python, \
        Please install Python 2.x \