Makefile 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include $(TOPDIR)/rules.mk
  4. PKG_NAME:= openjdk
  5. PKG_VERSION:= 6
  6. PKG_EXTRAVER:= b22-28_feb_2011
  7. PKG_RELEASE:= 2
  8. PKG_MD5SUM:= 2d2bbbb0f9b81f1fec41ec730da8a933 \
  9. fd3f35e8a8a2ef9a64c035ed66cea06d \
  10. ef7a8b3624ea904bf584bc46d79b5e75 \
  11. bc95c133620bd68c161cac9891592901 \
  12. 91adfd41e6f001add4f92ae31216b1e3 \
  13. d526d0848c88607ce4e3a0a4edb75d50
  14. PKG_DESCR:= OpenJDK Java VM
  15. PKG_SECTION:= lang
  16. PKG_URL:= http://openjdk.org/
  17. PKG_SITES:= http://download.java.net/openjdk/jdk6/promoted/b22/ \
  18. http://mirror.netcologne.de/apache.org/xml/xalan-j/binaries/ \
  19. http://icedtea.classpath.org/download/drops/ \
  20. http://icedtea.classpath.org/download/source/
  21. # autotools infrastructure for OpenJDK
  22. ICEDTEA_NAME:= icedtea6
  23. ICEDTEA_VERSION:= 1.10
  24. # bootstrap JARs
  25. XALAN_NAME= xalan-j
  26. XALAN_VERSION= 2_7_0
  27. # override generic extraction
  28. EXTRACT_OVERRIDE:= 1
  29. DISTFILES:= openjdk-$(PKG_VERSION)-src-$(PKG_EXTRAVER).tar.gz \
  30. $(ICEDTEA_NAME)-$(ICEDTEA_VERSION).tar.gz \
  31. jaxp144_01.zip \
  32. jdk6-jaf-b20.zip \
  33. jdk6-jaxws-b20.zip \
  34. ${XALAN_NAME}_${XALAN_VERSION}-bin.tar.gz
  35. WRKDIST= ${WRKDIR}
  36. WRKSRC= ${WRKDIST}/${ICEDTEA_NAME}-${ICEDTEA_VERSION}
  37. include ../rules.mk
  38. OPENJDK_NATIVE_ENV+= JAVACFLAGS="-cp ${STAGING_JAVA_HOST_DIR}/usr/share/java/libgcj-$(GCJ_VER).jar"
  39. OPENJDK_NATIVE_ENV+= DYLD_LIBRARY_PATH=$(STAGING_JAVA_HOST_DIR)/usr/lib:$(STAGING_JAVA_HOST_DIR)/usr/lib64
  40. OPENJDK_NATIVE_ENV+= LD_LIBRARY_PATH=$(STAGING_JAVA_HOST_DIR)/usr/lib:$(STAGING_JAVA_HOST_DIR)/usr/lib64
  41. OPENJDK_NATIVE_ENV+= ADK_ECJ=$(STAGING_JAVA_HOST_DIR)/usr/bin/ecj PATH=$$PATH:$(STAGING_JAVA_HOST_DIR)/usr/bin
  42. OPENJDK_NATIVE_ENV+= BOOTCLASSPATH="$(STAGING_JAVA_HOST_DIR)/usr/share/jamvm/classes.zip:$(STAGING_JAVA_HOST_DIR)/usr/share/classpath/glibj.zip"
  43. install: ${STAGING_JAVA_HOST_DIR}/bootstrap-jdk/bin/java
  44. do-extract:
  45. $(WRKDIST)/.extract: $(WRKDIST)/.extract_done
  46. cd ${WRKDIST}; mkdir openjdk-$(PKG_VERSION); \
  47. tar xzf $(TOPDIR)/dl/openjdk-$(PKG_VERSION)-src-$(PKG_EXTRAVER).tar.gz -C openjdk-$(PKG_VERSION)
  48. cd $(WRKDIST); tar xzf $(TOPDIR)/dl/$(ICEDTEA_NAME)-$(ICEDTEA_VERSION).tar.gz
  49. cd ${WRKDIST}; tar xzf ${TOPDIR}/dl/${XALAN_NAME}_${XALAN_VERSION}-bin.tar.gz
  50. mkdir -p ${WRKBUILD}/drops
  51. cd ${TOPDIR}/dl; cp jaxp144_01.zip jdk6-jaf-b20.zip jdk6-jaxws-b20.zip ${WRKBUILD}/drops
  52. cd $(WRKDIST); patch -p0 < ${TOPDIR}/jtools/openjdk/patches/openjdk.patch
  53. cd $(WRKDIST); patch -p0 < ${TOPDIR}/jtools/openjdk/patches/iconv.patch
  54. cd $(WRKDIST); patch -p0 < ${TOPDIR}/jtools/openjdk/patches/remove-libnsl.patch
  55. cd $(WRKDIST); patch -p0 < ${TOPDIR}/jtools/openjdk/patches/linux3.patch
  56. cd $(WRKDIST); patch -p0 < ${TOPDIR}/jtools/openjdk/patches/disable-backtrace.patch
  57. touch $@
  58. $(WRKDIST)/.configured: ${WRKDIST}/.extract
  59. cd ${WRKBUILD}; rm -rf config.{cache,status}; \
  60. export ${OPENJDK_NATIVE_ENV}; ./configure \
  61. --enable-bootstrap \
  62. --enable-zero \
  63. --disable-openjdk-cross-compilation \
  64. --with-openjdk-src-dir=$(WRKDIST)/$(PKG_NAME)-$(PKG_VERSION) \
  65. --with-jdk-home=$(STAGING_JAVA_HOST_DIR)/usr/lib/jvm \
  66. --with-java=$(STAGING_JAVA_HOST_DIR)/usr/bin/java \
  67. --with-javac=$(STAGING_JAVA_HOST_DIR)/usr/bin/ecj \
  68. --with-gcj=$(STAGING_JAVA_HOST_DIR)/usr/bin/gcj \
  69. --with-ecj-jar=${STAGING_JAVA_HOST_DIR}/usr/share/java/ecj.jar \
  70. --with-xalan2-jar=${WRKDIST}/${XALAN_NAME}_${XALAN_VERSION}/xalan.jar \
  71. --with-xalan2-serializer-jar=${WRKDIST}/${XALAN_NAME}_${XALAN_VERSION}/serializer.jar \
  72. --with-xerces2-jar=${WRKDIST}/${XALAN_NAME}_${XALAN_VERSION}/xercesImpl.jar \
  73. --without-rhino \
  74. --disable-docs
  75. touch $@
  76. $(WRKBUILD)/.compiled: ${WRKDIST}/.configured
  77. export ${OPENJDK_NATIVE_ENV}; $(MAKE) -C $(WRKBUILD)
  78. touch $@
  79. ${STAGING_JAVA_HOST_DIR}/bootstrap-jdk/bin/java: $(WRKBUILD)/.compiled
  80. $(CP) $(WRKSRC)/openjdk.build/j2sdk-image $(STAGING_JAVA_HOST_DIR)/bootstrap-jdk
  81. touch $@
  82. include ${TOPDIR}/mk/pkg-bottom.mk