# $Id: $ PortSystem 1.0 name openjdk6 version b16 revision 1 set builddate 24_apr_2009 categories java maintainers landonf openmaintainer platforms darwin homepage http://openjdk.java.net/ description Sun's java 6 virtual machine release under the GNUV2 license long_description \ OpenJDK is an open-source implementation of the Java Platform, Standard Edition. \ The version has all of Sun's bug fixes up to JDK 6 Release 11 and should be \ the runtime equivelent to JDK6 Release 11. \ \ Much of the OpenJDK code is licensed under the GPL version 2 with the \ Classpath exception. The Java Hotspot virtual machine source code is \ licensed under the GPL version 2 only. distname openjdk-6-src-${version}-${builddate} master_sites http://download.java.net/openjdk/jdk6/promoted/${version}/ checksums md5 850a29b70206bc7fa083cd26acc781f3 \ sha256 96159489d8b70db275c125b627c6e6912e6c078279d76b968d2e0969359c9420 patchfiles patch-set \ patch-null_word_intptr_t \ patch-jdk_src_solaris_javavm_include_typedefs__md.h \ patch-jvm_base_addr \ patch-jdk_src_share_java.c \ patch-jdk_src_solaris_native_common_gdefs__md.h \ patch-10.4-ucontext \ patch-disable_test_gamma use_configure no depends_lib port:freetype \ port:openmotif \ port:xorg-libX11 \ port:xorg-libXtst depends_build port:icedtea6-plugs \ port:apache-ant # Check if the boostrap is required if {[file exists ${prefix}/share/java/openjdk6/bin/java]} { # A previous OpenJDK6 release is already installed set bootstrapvm "${prefix}/share/java/openjdk6" } else { # A bootstrap binary is required to build depends_build-append port:openjdk6_bootstrap set bootstrapvm "${prefix}/share/java/openjdk6_bootstrap" } worksrcdir "./" post-extract { set copydirs { \ hotspot/src/os/linux/launcher \ hotspot/src/os/linux/vm \ hotspot/src/os_cpu/linux_x86/vm \ hotspot/build/linux \ hotspot/build/linux/makefiles \ jdk/src/linux/doc/man } set copyfiles { \ corba/make/common/Defs-linux.gmk \ corba/make/common/shared/Defs-linux.gmk \ jdk/make/common/Defs-linux.gmk \ jdk/make/common/shared/Defs-linux.gmk \ jdk/make/java/nio/mapfile-linux \ jdk/make/netbeans/common/architectures/name-Linux.properties \ jdk/make/sun/awt/mapfile-vers-linux \ jdk/make/tools/sharing/classlist.linux \ jdk/src/solaris/classes/java/lang/UNIXProcess.java.linux \ jdk/src/solaris/classes/sun/awt/fontconfigs/linux.fontconfig.properties \ jdk/src/solaris/classes/sun/tools/attach/LinuxAttachProvider.java \ jdk/src/solaris/hpi/include/largefile_linux.h \ jdk/src/solaris/native/java/net/linux_close.c \ jdk/src/solaris/native/sun/tools/attach/LinuxVirtualMachine.c } # Copy over original Linux sources foreach src ${copydirs} { set dest "${worksrcpath}/[strsed ${src} g/linux/bsd/]" # Create the parent directories file mkdir "${dest}" # Copy the contents, adjust file contents foreach srcfile [glob -types f "${worksrcpath}/${src}/*"] { set destfile "${dest}/[strsed [file tail ${srcfile}] g/linux/bsd/]" copy "${srcfile}" "${destfile}" reinplace "s/linux/bsd/g; s/Linux/Bsd/g" "${destfile}" reinplace "s/linux/bsd/g; s/Linux/Bsd/g" "${destfile}" } } foreach src ${copyfiles} { set dest "${worksrcpath}/[exec echo ${src} | sed {s/linux/bsd/g; s/Linux/Bsd/g}]" copy "${worksrcpath}/${src}" "${dest}" reinplace "s/linux/bsd/g; s/Linux/Bsd/g" "${dest}" } # Copy the solaris sources copy "${worksrcpath}/jdk/src/solaris/hpi/native_threads/src/threads_solaris.c" \ "${worksrcpath}/jdk/src/solaris/hpi/native_threads/src/threads_bsd.c" reinplace "s/solaris/bsd/g; s/Solaris/Bsd/g" \ "${worksrcpath}/jdk/src/solaris/hpi/native_threads/src/threads_bsd.c" copy "${worksrcpath}/jdk/src/share/lib/security/java.security" \ "${worksrcpath}/jdk/src/share/lib/security/java.security-openbsd" } build.args \ ALT_BOOTDIR="${bootstrapvm}" \ ALT_BINARY_PLUGS_PATH="${prefix}/share/java/icedtea6-plugs/jre/lib/rt-closed.jar" \ ANT_HOME="${prefix}/share/java/apache-ant" \ ALT_FREETYPE_HEADERS_PATH="${prefix}/include" \ ALT_FREETYPE_LIB_PATH="${prefix}/lib" \ ALT_CUPS_HEADERS_PATH="/usr/include" \ ALT_MOTIF_DIR="${prefix}" \ ALT_X11_PATH="${prefix}" \ ALT_DEVTOOLS_PATH=/usr \ ALT_CACERTS_FILE=/System/Library/Frameworks/JavaVM.framework/Home/lib/security/cacerts \ NO_DOCS=true \ HOTSPOT_BUILD_JOBS=[expr [exec sysctl -n hw.ncpu] - 1] destroot { set path "${destroot}${prefix}/share/java/${name}/" xinstall -m 755 -d ${path} system "(cd ${worksrcpath}/build/bsd-i586/j2sdk-image && tar cf - *) | (tar -C ${path} -xf -)" }