Skip site navigation (1)Skip section navigation (2)
Date:      Tue,  1 Apr 2008 00:26:24 +0200
From:      "Björn König" <bkoenig@alpha-tierchen.de>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/122311: Update port java/classpath to 0.93
Message-ID:  <20080331222623.874E628545@home.alpha-tierchen.de>
Resent-Message-ID: <200803312230.m2VMU1kg043756@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         122311
>Category:       ports
>Synopsis:       Update port java/classpath to 0.93
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 31 22:30:01 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Björn König
>Release:        
>Organization:
>Environment:
>Description:
	The patch updates the port java/classpath to 0.93. Furthermore it
	adds options to enable the Gtk+ and/or Qt AWT peer. I also like to
	take the maintainership of this port.

	Although classpath 0.97.1 is already available I updated the port to 0.93
	because at the time this older version is the last one which can be compiled
	with jikes and does not require a fat jdk. I plan to update later.

	
>How-To-Repeat:
	
>Fix:
	

--- java-classpath.diff begins here ---
diff --git a/java/classpath/Makefile b/java/classpath/Makefile
index 5adfb5a..9a70adc 100644
--- a/java/classpath/Makefile
+++ b/java/classpath/Makefile
@@ -7,31 +7,74 @@
 #
 
 PORTNAME=	classpath
-PORTVERSION=	0.92
-PORTREVISION=	2
+PORTVERSION=	0.93
 CATEGORIES=	java devel
 MASTER_SITES=	${MASTER_SITE_GNU} \
 		${MASTER_SITE_SAVANNAH}
 MASTER_SITE_SUBDIR=	${PORTNAME}
 
-MAINTAINER=	ports@FreeBSD.org
+MAINTAINER=	bkoenig@alpha-tierchen.de
 COMMENT=	A GNU project to create a free Java class library
 
-BUILD_DEPENDS=	zip:${PORTSDIR}/archivers/zip
+BUILD_DEPENDS=	zip:${PORTSDIR}/archivers/zip \
+		jikes:${PORTSDIR}/java/jikes
 
 USE_LDCONFIG=	yes
-USE_JAVA=	yes
-USE_JIKES=	yes
-USE_GNOME=	gtk20 gdkpixbuf pkgconfig gconf2
+USE_GNOME=	gnometarget
 GNU_CONFIGURE=	yes
-PKG_CONFIG?=	${LOCALBASE}/bin/pkg-config
-CONFIGURE_ENV=	CPPFLAGS="${CXXFLAGS} `${PKG_CONFIG} gtk+-2.0 --cflags`" \
-		LDFLAGS="`${PKG_CONFIG} gtk+-2.0 --libs`"
-CONFIGURE_ARGS=	--enable-jni --with-jikes --disable-gtk-peer --disable-plugin
+CONFIGURE_ENV=	CXXFLAGS="${CXXFLAGS} -I${LOCALBASE}/include"
+CONFIGURE_ARGS=	--enable-jni --with-jikes --disable-alsa --disable-dssi --disable-plugin
 USE_GMAKE=	yes
 
 INFO=		hacking tools vmintegration
 
 CONFLICTS=	sablevm-classpath-*
 
-.include <bsd.port.mk>
+OPTIONS=	GCONF "Use GConf based preferences backend" OFF \
+		GTK2 "Enable Gtk+ AWT peer" ON \
+		CAIRO "Use Gtk+ Cairo based Graphics2D" OFF \
+		QT4 "Enable Qt AWT peer" OFF
+
+.include <bsd.port.pre.mk>
+
+.if defined(WITH_GCONF)
+USE_GNOME+=		gconf2
+CONFIGURE_ARGS+=	--enable-default-preferences-peer=gconf
+PLIST_SUB+=		GCONF=""
+.else
+CONFIGURE_ARGS+=	--enable-default-preferences-peer=file --disable-gconf-peer
+PLIST_SUB+=		GCONF="@comment "
+.endif
+
+.if defined(WITHOUT_GTK2)
+CONFIGURE_ARGS+=	--disable-gtk-peer
+PLIST_SUB+=		GTK2="@comment "
+.if defined(WITH_CAIRO)
+IGNORE=you need to enable the Gtk+ AWT peer in order to use Cairo based Graphics2D.
+.endif
+.else
+USE_GNOME+=		gtk20
+PLIST_SUB+=		GTK2=""
+.if defined(WITH_CAIRO)
+CONFIGURE_ARGS+=	--enable-gtk-cairo
+.endif
+.endif
+
+.if defined(WITH_QT4)
+CONFIGURE_ARGS+=	--enable-qt-peer
+.if defined(WITHOUT_GTK2)
+CONFIGURE_ARGS+=	--enable-default-toolkit=gnu.java.awt.peer.qt.QtToolkit
+.endif
+CONFIGURE_ENV+=		MOC="${LOCALBASE}/bin/moc-qt4"
+USE_QT_VER=		4
+QT_COMPONENTS=		moc_build corelib_run gui_run
+PLIST_SUB+=		QT4=""
+.else
+PLIST_SUB+=		QT4="@comment "
+.endif
+
+post-extract:
+	@${REINPLACE_CMD} -e 's,^\(include_HEADERS = \)jni.h jni_md.h \(.*\),\1\2,' \
+		${WRKSRC}/include/Makefile.in
+
+.include <bsd.port.post.mk>
diff --git a/java/classpath/distinfo b/java/classpath/distinfo
index 2d70d4a..bb2615b 100644
--- a/java/classpath/distinfo
+++ b/java/classpath/distinfo
@@ -1,3 +1,3 @@
-MD5 (classpath-0.92.tar.gz) = 4603ef3e593713d94788b919bc0b6c75
-SHA256 (classpath-0.92.tar.gz) = 8bc678263b40635623995826a3c1f0ea177dba9cc29bfe6572cc8acdb182b0d0
-SIZE (classpath-0.92.tar.gz) = 9161101
+MD5 (classpath-0.93.tar.gz) = ffa9e9cac31c5acbf0ea9eff9efa923d
+SHA256 (classpath-0.93.tar.gz) = df2d093612abd23fe67e9409d89bb2a8e79b1664fe2b2da40e1c8ed693e32945
+SIZE (classpath-0.93.tar.gz) = 9534222
diff --git a/java/classpath/files/patch-native_jni_native-lib_cpnet.h b/java/classpath/files/patch-native_jni_native-lib_cpnet.h
new file mode 100644
index 0000000..efce85c
--- /dev/null
+++ b/java/classpath/files/patch-native_jni_native-lib_cpnet.h
@@ -0,0 +1,14 @@
+--- native/jni/native-lib/cpnet.h.orig	2006-09-08 10:59:57.000000000 +0200
++++ native/jni/native-lib/cpnet.h	2008-03-31 18:47:54.000000000 +0200
+@@ -41,9 +41,11 @@
+ #include <jni.h>
+ #include <jcl.h>
+ #include <string.h>
+ 
++#include <sys/types.h>
+ #include <sys/socket.h>
++#include <netinet/in_systm.h>
+ #include <netinet/in.h>
+ #include <netinet/ip.h>
+ 
+ typedef struct {
diff --git a/java/classpath/pkg-plist b/java/classpath/pkg-plist
index 94f7321..c8e4fc0 100644
--- a/java/classpath/pkg-plist
+++ b/java/classpath/pkg-plist
@@ -3,14 +3,17 @@ bin/gjar
 bin/gjarsigner
 bin/gkeytool
 bin/gnative2ascii
+bin/gorbd
+bin/grmid
+bin/grmiregistry
 bin/gserialver
+bin/gtnameserv
 include/jawt.h
 include/jawt_md.h
-include/jni.h
-include/jni_md.h
-lib/classpath/libgconfpeer.la
-lib/classpath/libgconfpeer.so
-lib/classpath/libgconfpeer.so.0
+%%GCONF%%lib/classpath/libgconfpeer.la
+%%GCONF%%lib/classpath/libgconfpeer.so
+%%GTK2%%lib/classpath/libgtkpeer.so
+%%GTK2%%lib/classpath/libgtkpeer.la
 lib/classpath/libjavaio.la
 lib/classpath/libjavaio.so
 lib/classpath/libjavaio.so.0
@@ -29,11 +32,14 @@ lib/classpath/libjavanio.so.0
 lib/classpath/libjavautil.la
 lib/classpath/libjavautil.so
 lib/classpath/libjavautil.so.0
+%%GTK2%%lib/classpath/libjawt.so
+%%GTK2%%lib/classpath/libjawt.la
+%%QT4%%lib/classpath/libqtpeer.so
+%%QT4%%lib/classpath/libqtpeer.la
 lib/logging.properties
 lib/security/classpath.security
 @dirrm lib/classpath
 @dirrm lib/security
-%%DATADIR%%/README
 %%DATADIR%%/examples/Makefile.java2d
 %%DATADIR%%/examples/Makefile.jawt
 %%DATADIR%%/examples/README
@@ -81,10 +87,12 @@ lib/security/classpath.security
 %%DATADIR%%/examples/gnu/classpath/examples/awt/Demo.java
 %%DATADIR%%/examples/gnu/classpath/examples/datatransfer/Demo.java
 %%DATADIR%%/examples/gnu/classpath/examples/html/Demo.java
+%%DATADIR%%/examples/gnu/classpath/examples/icons/back.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/badge.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/big-fullscreen.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/big-home.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/big-warning.png
+%%DATADIR%%/examples/gnu/classpath/examples/icons/reload.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/stock-copy.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/stock-cut.png
 %%DATADIR%%/examples/gnu/classpath/examples/icons/stock-go-back.png
@@ -117,6 +125,7 @@ lib/security/classpath.security
 %%DATADIR%%/examples/gnu/classpath/examples/management/TestThread.java
 %%DATADIR%%/examples/gnu/classpath/examples/midi/Demo.java
 %%DATADIR%%/examples/gnu/classpath/examples/print/Demo.java
+%%DATADIR%%/examples/gnu/classpath/examples/swing/BrowserEditorKit.java
 %%DATADIR%%/examples/gnu/classpath/examples/swing/ButtonDemo.java
 %%DATADIR%%/examples/gnu/classpath/examples/swing/ComboBoxDemo.java
 %%DATADIR%%/examples/gnu/classpath/examples/swing/Demo.java
@@ -138,6 +147,15 @@ lib/security/classpath.security
 %%DATADIR%%/examples/gnu/classpath/examples/swing/TextAreaDemo.java
 %%DATADIR%%/examples/gnu/classpath/examples/swing/TextFieldDemo.java
 %%DATADIR%%/examples/gnu/classpath/examples/swing/TreeDemo.java
+%%DATADIR%%/examples/gnu/classpath/examples/swing/forms.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/frame1.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/frame2.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/frame3.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/frame4.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/frames.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/tables.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/textstyles.html
+%%DATADIR%%/examples/gnu/classpath/examples/swing/welcome.html
 %%DATADIR%%/glibj.zip
 %%DATADIR%%/tools.zip
 @dirrm %%DATADIR%%/examples/gnu/classpath/examples/swing
--- java-classpath.diff ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080331222623.874E628545>