123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124 |
- # This file is part of the OpenADK project. OpenADK is copyrighted
- # material, please see the LICENCE file in the top-level directory.
- include ${TOPDIR}/rules.mk
- PKG_NAME:= python3
- PKG_VERSION:= 3.3.2
- PKG_RELEASE:= 3
- PKG_MD5SUM:= 0a2ea57f6184baf45b150aee53c0c8da
- PKG_DESCR:= Python scripting language (Version 3)
- PKG_SECTION:= lang
- PKG_DEPENDS:= libpthread libgcc libffi
- PKG_BUILDDEP:= python3-host libffi
- PKG_URL:= http://www.python.org/
- PKG_SITES:= http://www.python.org/ftp/python/${PKG_VERSION}/
- PKG_HOST_DEPENDS:= !netbsd !openbsd !cygwin
- PKG_FLAVOURS_PYTHON3:= MOD_ZLIB MOD_BZ2 MOD_EXPAT MOD_SQLITE MOD_GDBM
- PKG_FLAVOURS_PYTHON3+= MOD_NCURSES MOD_SSL MOD_READLINE
-
- PKGFD_MOD_ZLIB:= ZLIB support
- PKGFB_MOD_ZLIB:= zlib
- PKGFS_MOD_ZLIB:= zlib
- PKGFD_MOD_BZ2:= BZIP2 support
- PKGFB_MOD_BZ2:= bzip2
- PKGFS_MOD_BZ2:= libbz2
- PKGFD_MOD_EXPAT:= XML support
- PKGFB_MOD_EXPAT:= expat
- PKGFS_MOD_EXPAT:= libexpat
- PKGFD_MOD_SQLITE:= SQLITE support
- PKGFB_MOD_SQLITE:= sqlite
- PKGFS_MOD_SQLITE:= libsqlite
- PKGFD_MOD_GDBM:= GDBM support
- PKGFB_MOD_GDBM:= gdbm
- PKGFS_MOD_GDBM:= libgdbm
- PKGFD_MOD_NCURSES:= NCURSES support
- PKGFB_MOD_NCURSES:= ncurses
- PKGFS_MOD_NCURSES:= libncurses
- PKGFD_MOD_READLINE:= READLINE support
- PKGFB_MOD_READLINE:= readline
- PKGFS_MOD_READLINE:= libreadline
- PKGFD_MOD_SSL:= OpenSSL support
- PKGFB_MOD_SSL:= openssl
- PKGFS_MOD_SSL:= libopenssl
- DISTFILES= Python-${PKG_VERSION}.tgz
- WRKDIST= ${WRKDIR}/Python-${PKG_VERSION}
- include ${TOPDIR}/mk/host.mk
- include ${TOPDIR}/mk/package.mk
- define PKG_mod_template
- INSTALL_MODS_$${ADK_PACKAGE_${1}}+= ${2}-install
- ${2}-install:
- ${INSTALL_DIR} $$(IDIR_$(1))/usr/lib/python3.3/lib-dynload
- for m in ${2}; do \
- ${INSTALL_DATA} $(WRKINST)/usr/lib/python3.3/lib-dynload/$$$${m}*.so $$(IDIR_$(1))/usr/lib/python3.3/lib-dynload ;\
- done
- endef
- $(eval $(call HOST_template,PYTHON3,python3,${PKG_VERSION}-${PKG_RELEASE}))
- $(eval $(call PKG_template,PYTHON3,python3,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_ZLIB,python3-mod-zlib,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_ZLIB},${PKGFD_MOD_ZLIB},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_BZ2,python3-mod-bz2,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_BZ2},${PKGFD_MOD_BZ2},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_EXPAT,python3-mod-expat,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_EXPAT},${PKGFD_MOD_EXPAT},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_SQLITE,python3-mod-sqlite,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_SQLITE},${PKGFD_MOD_SQLITE},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_GDBM,python3-mod-gdbm,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_GDBM},${PKGFD_MOD_GDBM},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_NCURSES,python3-mod-ncurses,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_NCURSES},${PKGFD_MOD_NCURSES},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_SSL,python3-mod-ssl,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_SSL},${PKGFD_MOD_SSL},${PKG_SECTION}))
- $(eval $(call PKG_template,PYTHON3_MOD_READLINE,python3-mod-readline,$(PKG_VERSION)-${PKG_RELEASE},${PKGFS_MOD_READLINE},${PKGFD_MOD_READLINE},${PKG_SECTION}))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_ZLIB,zlib))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_BZ2,_bz2))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_EXPAT,pyexpat))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_SQLITE,_sqlite))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_GDBM,_gdbm))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_NCURSES,_curses))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_SSL,_ssl))
- $(eval $(call PKG_mod_template,PYTHON3_MOD_READLINE,readline))
- MAKE_ENV+= HOSTPGEN=$(STAGING_HOST_DIR)/usr/bin/pgen3
- CONFIGURE_ARGS:= --with-threads \
- --with-system-ffi \
- --with-system-expat \
- --disable-ipv6 \
- --without-cxx-main
- CONFIGURE_ENV+= ac_cv_have_long_long_format=yes \
- ac_cv_file__dev_ptmx=yes \
- ac_cv_file__dev_ptc=no
- HOST_CONFIGURE_ARGS+= --without-cxx-main \
- --without-threads
-
- python3-hostinstall:
- $(INSTALL_BIN) ${HOST_WRKINST}/usr/bin/python3 \
- $(STAGING_HOST_DIR)/usr/bin
- $(INSTALL_BIN) ${WRKBUILD}/Parser/pgen \
- $(STAGING_HOST_DIR)/usr/bin/pgen3
- $(CP) $(HOST_WRKINST)/usr/lib/python3.3 \
- $(STAGING_HOST_DIR)/usr/lib
- $(INSTALL_DIR) $(STAGING_HOST_DIR)/usr/include/python3.3m
- ${CP} ${HOST_WRKINST}/usr/include/python3.3m/pyconfig.h \
- $(STAGING_HOST_DIR)/usr/include/python3.3m
- python3-install: ${INSTALL_MODS_y} ${INSTALL_MODS_m}
- ${INSTALL_DIR} ${IDIR_PYTHON3}/usr/bin ${IDIR_PYTHON3}/usr/lib
- ${INSTALL_DIR} ${IDIR_PYTHON3}/usr/lib/python3.3
- ${INSTALL_DIR} ${IDIR_PYTHON3}/usr/include/python3.3m
- ${INSTALL_BIN} ${WRKINST}/usr/bin/python3 ${IDIR_PYTHON3}/usr/bin
- ${CP} ${WRKINST}/usr/lib/libpython*.so* ${IDIR_PYTHON3}/usr/lib
- ${CP} ${WRKINST}/usr/lib/python3.3/* ${IDIR_PYTHON3}/usr/lib/python3.3
- ${CP} ${WRKINST}/usr/include/python3.3m/pyconfig.h \
- ${IDIR_PYTHON3}/usr/include/python3.3m
- @-for i in zlib _bz2 _curses _ssl _gdbm _sqlite pyexpat readline; do \
- rm ${IDIR_PYTHON3}/usr/lib/python3.3/lib-dynload/$${i}*so; \
- done
- include ${TOPDIR}/mk/host-bottom.mk
- include ${TOPDIR}/mk/pkg-bottom.mk
|