Makefile 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637
  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:= ecj
  5. PKG_VERSION:= 1
  6. PKG_RELEASE:= 2
  7. PKG_MD5SUM:= 63220327925ace13756ae334c55a3baa
  8. include ../rules.mk
  9. install: ${STAGING_JAVA_HOST_DIR}/usr/bin/ecj
  10. ${STAGING_JAVA_HOST_DIR}/usr/bin/ecj:
  11. env \
  12. DYLD_LIBRARY_PATH=$(STAGING_JAVA_HOST_DIR)/usr/lib:$(STAGING_JAVA_HOST_DIR)/usr/lib64 \
  13. LD_LIBRARY_PATH=$(STAGING_JAVA_HOST_DIR)/usr/lib:$(STAGING_JAVA_HOST_DIR)/usr/lib64 \
  14. PATH=$(STAGING_JAVA_HOST_DIR)/usr/bin:$$PATH \
  15. $(STAGING_JAVA_HOST_DIR)/usr/bin/gcj -g -O2 -findirect-dispatch \
  16. -o ${STAGING_JAVA_HOST_DIR}/usr/bin/ecj.native \
  17. --main=org.eclipse.jdt.internal.compiler.batch.Main \
  18. $(TOPDIR)/jtools_build/gcc-4.5.2/ecj.jar
  19. $(CP) $(TOPDIR)/jtools_build/gcc-4.5.2/ecj.jar ${STAGING_JAVA_HOST_DIR}/usr/share/ecj.jar
  20. echo "env LD_LIBRARY_PATH=$(STAGING_JAVA_HOST_DIR)/usr/lib:$(STAGING_JAVA_HOST_DIR)/usr/lib64 ${STAGING_JAVA_HOST_DIR}/usr/bin/ecj.native \$$@" > \
  21. ${STAGING_JAVA_HOST_DIR}/usr/bin/ecj
  22. chmod u+x ${STAGING_JAVA_HOST_DIR}/usr/bin/ecj
  23. # put a wrapper for java here
  24. echo "env LD_LIBRARY_PATH=$(STAGING_JAVA_HOST_DIR)/usr/lib:$(STAGING_JAVA_HOST_DIR)/usr/lib64 ${STAGING_JAVA_HOST_DIR}/usr/bin/gij \"\$$@\"" > \
  25. ${STAGING_JAVA_HOST_DIR}/usr/bin/java
  26. chmod u+x ${STAGING_JAVA_HOST_DIR}/usr/bin/java
  27. rm ${STAGING_JAVA_HOST_DIR}/usr/lib/jvm/bin/java
  28. rm ${STAGING_JAVA_HOST_DIR}/usr/lib/jvm/jre/bin/java
  29. cp ${STAGING_JAVA_HOST_DIR}/usr/bin/java ${STAGING_JAVA_HOST_DIR}/usr/lib/jvm/bin/java
  30. cp ${STAGING_JAVA_HOST_DIR}/usr/bin/java ${STAGING_JAVA_HOST_DIR}/usr/lib/jvm/jre/bin/java
  31. include $(TOPDIR)/mk/tools.mk