ndt-dev - [ndt-dev] [ndt] r1113 committed - Add a "precompiled" java Applet (signed with an Internet2 signing cert...
Subject: NDT-DEV email list created
List archive
[ndt-dev] [ndt] r1113 committed - Add a "precompiled" java Applet (signed with an Internet2 signing cert...
Chronological Thread
- From:
- To:
- Subject: [ndt-dev] [ndt] r1113 committed - Add a "precompiled" java Applet (signed with an Internet2 signing cert...
- Date: Wed, 25 Jun 2014 17:56:53 +0000
Revision: 1113
Author:
Date: Wed Jun 25 17:56:39 2014 UTC
Log: Add a "precompiled" java Applet (signed with an Internet2 signing cert), and
have the RPM use that instead of rebuilding the Applet when building. This is
needed if RPM building is going to be automated at all since the signing needs
to either happen before build time, or during build time, and the latter is
impossible unless you build the Applet by hand.
http://code.google.com/p/ndt/source/detail?r=1113
Added:
/trunk/Applet/precompiled
/trunk/Applet/precompiled/Tcpbw100.jar
/trunk/Applet/precompiled/lib
/trunk/Applet/precompiled/lib/json-simple-1.1.1.jar
Modified:
/trunk/Applet/MANIFEST.MF
/trunk/Applet/Makefile.am
/trunk/Makefile.am
/trunk/configure.ac
/trunk/ndt.spec
=======================================
--- /dev/null
+++ /trunk/Applet/precompiled/Tcpbw100.jar Wed Jun 25 17:56:39 2014 UTC
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/Applet/precompiled/lib/json-simple-1.1.1.jar Wed Jun 25 17:56:39 2014 UTC
Binary file, no diff available.
=======================================
--- /trunk/Applet/MANIFEST.MF Wed May 28 11:17:18 2014 UTC
+++ /trunk/Applet/MANIFEST.MF Wed Jun 25 17:56:39 2014 UTC
@@ -1,4 +1,5 @@
Manifest-Version: 1.0
-Class-Path: lib/json-smart-1.1.1.jar
-Created-By: My own fingers
+Class-Path: lib/json-simple-1.1.1.jar
+Created-By: Rich Carlson
Main-Class: edu.internet2.ndt.Tcpbw100
+Permissions: sandbox
=======================================
--- /trunk/Applet/Makefile.am Mon Jun 23 19:06:26 2014 UTC
+++ /trunk/Applet/Makefile.am Wed Jun 25 17:56:39 2014 UTC
@@ -32,68 +32,46 @@
noinst_PROGRAMS = Tcpbw100.jar
-Tcpbw100_JAVA = src/edu/internet2/ndt/Tcpbw100.java
Tcpbw100_jar_SOURCES = src/edu/internet2/ndt/Tcpbw100.java src/edu/internet2/ndt/StatusPanel.java \
src/edu/internet2/ndt/Protocol.java src/edu/internet2/ndt/Message.java \
src/edu/internet2/ndt/UserAgentTools.java src/edu/internet2/ndt/NDTConstants.java \
src/edu/internet2/ndt/OsfwWorker.java src/edu/internet2/ndt/NewFrame.java \
src/edu/internet2/ndt/ResultsTextPane.java src/edu/internet2/ndt/MessageType.java \
src/edu/internet2/ndt/NDTUtils.java src/edu/internet2/ndt/JSONUtils.java
-Tcpbw100$(EXEEXT): $(Tcpbw100_OBJECTS) $(Tcpbw100_DEPENDENCIES)
- @rm -f Tcpbw100$(EXEEXT)
- @if test ! -s "classTcpbw100.stamp"; then \
- $(GCJLINK) $(Tcpbw100_LDFLAGS) $(Tcpbw100_OBJECTS) $(Tcpbw100_LDADD) $(LIBS); \
- echo timestamp > classTcpbw100.stamp; \
- else :; fi
-
-#classTcpbw100stamp: $(Tcpbw100_JAVA)
-# if test -n "$?"; then \
-# echo '$(GCJ) $(NDTGCJFLAGS) $?' ; \
-# $(GCJ) $(NDTGCJFLAGS) $?; \
-# else :; fi
-# echo timestamp > classTcpbw100.stamp
-
-classTcpbw100stamp: $(Tcpbw100_jar_SOURCES)
- if test -n "$?"; then \
- echo '$(GCJ) $(NDTGCJFLAGS) $?' ; \
- $(GCJ) $(NDTGCJFLAGS) $?; \
- else :; fi
- echo timestamp > classTcpbw100.stamp
-
bin:
mkdir -p bin
dist:
mkdir -p dist
-#Tcpbw100.class: $(Tcpbw100_JAVA)
-# $(GCJ) $(NDTGCJFLAGS) $(Tcpbw100_JAVA)
-
-#Tcpbw100.jar: Tcpbw100.class
-# $(NDTJAR) $(NDTJARFLAG) MANIFEST.MF Tcpbw100.jar Tcpbw100*.class Tcpbw100*.properties
-# echo timestamp > classTcpbw100.stamp
-#All classes to be compiled into their corresponding class files
.java.class:
+if BUILD_APPLET
$(GCJ) $(NDTGCJFLAGS) $<
+else
+ touch $<
+endif
#All classes to be compiled into their corresponding class files
all.class: $(Tcpbw100_jar_SOURCES:.java=.class)
-#
-# $(GCJ) $(NDTGCJFLAGS) $(Tcpbw100_jar_SOURCES)
#dependency management
Tcpbw100.class: StatusPanel.class Protocol.class Message.class UserAgentTools.class NDTConstants.class OsfwWorker.class NewFrame.class ResultsTextPane.class MessageType.class NDTUtils.class
Protocol.class: Message.class
OsfwWorker.class: NDTConstants.class Message.class Protocol.class
-
#Include all classes into jar
Tcpbw100.jar: $(TEMPDIRS) all.class
+if BUILD_APPLET
mkdir -p bin/edu/internet2/ndt/locale
cp -r src/edu/internet2/ndt/locale/* bin/edu/internet2/ndt/locale
$(NDTJAR) $(NDTJARFLAG) MANIFEST.MF dist/Tcpbw100.jar -C bin .
mkdir -p dist/lib
cp -r lib/* dist/lib
+else
+ mkdir -p dist/lib
+ cp -r precompiled/lib/* dist/lib
+ cp -r precompiled/Tcpbw100.jar dist
+endif
if test -n "$(CERTIFICATE_FILE)"; then \
$(NDTJARSIGNER) $(NDTJARSIGNERFLAG) $(CERTIFICATE_FILE) $(ndt_DATA) $(ALIAS); \
$(NDTJARSIGNER) $(NDTJARSIGNERFLAG) $(CERTIFICATE_FILE) dist/$(jsonlib) $(ALIAS); \
@@ -112,4 +90,4 @@
src/edu/internet2/ndt/locale/Tcpbw100_msgs_ru_RU.properties \
src/edu/internet2/ndt/locale/Tcpbw100_msgs_pt_BR.properties \
src/edu/internet2/ndt/locale/Tcpbw100_msgs_el_GR.properties \
- $(jsonlib)
+ $(jsonlib) precompiled/$(jsonlib)
precompiled/Tcpbw100.jar
=======================================
--- /trunk/Makefile.am Fri Jun 20 14:26:21 2014 UTC
+++ /trunk/Makefile.am Wed Jun 25 17:56:39 2014 UTC
@@ -19,7 +19,7 @@
SUBDIRS = @TOP_BUILD_DIRS@ src conf doc
if HAVE_GCJ
SUBDIRS += Admin janalyze
-if BUILD_APPLET
+if INCLUDE_APPLET
SUBDIRS += Applet
endif
if HAVE_MXMLC
=======================================
--- /trunk/configure.ac Fri Jun 20 14:26:21 2014 UTC
+++ /trunk/configure.ac Wed Jun 25 17:56:39 2014 UTC
@@ -78,11 +78,35 @@
AC_MSG_RESULT(yes)
fi
-# Enabling/disabling java client build
-AC_ARG_ENABLE(java, [ --enable-java=[yes/no] turn on java applet build
- [default=yes]],, enable_java=yes)
+AC_ARG_WITH([java],
+ [AS_HELP_STRING([--with-java],
+ [Enable java client @<:@default=auto@:>@ (yes/no/precompiled/auto)])],
+ [],
+ [with_java=auto])
-if test "x$enable_java" != "xno"; then
+if test "x$with_java" == "xauto"; then
+ AC_CHECK_PROGS(JAVAC, javac)
+ if test -n "$JAVAC"; then
+ with_java=yes
+ else
+ with_java=precompiled
+ fi
+fi
+
+if test "x$with_java" == "xyes"; then
+ AC_CHECK_PROGS(JAVAC, javac)
+ if test -z "$JAVAC"; then
+ AC_MSG_FAILURE([javac required to rebuild java applet but not available])
+ fi
+fi
+
+if test "x$with_java" != "xno"; then
+ AM_CONDITIONAL(INCLUDE_APPLET, true)
+else
+ AM_CONDITIONAL(INCLUDE_APPLET, false)
+fi
+
+if test "x$with_java" != "xprecompiled"; then
AM_CONDITIONAL(BUILD_APPLET, true)
else
AM_CONDITIONAL(BUILD_APPLET, false)
@@ -419,17 +443,17 @@
SUMMARY_GENPLOT="NO (missing web100 library)"
fi
+if test "x$with_java" == "xno"; then
+SUMMARY_TCPBW100JAR="NO"
+else
+SUMMARY_TCPBW100JAR="YES"
+fi
+
if test -z "$HAVE_GCJ_TRUE" && test -n "$HAVE_GCJ_FALSE"; then
SUMMARY_ADMINCLASS="YES"
-if test "x$enable_java" != "xno"; then
-SUMMARY_TCPBW100JAR="YES"
-else
-SUMMARY_TCPBW100JAR="NO (disabled by user)"
-fi
SUMMARY_JANALYZEJAR="YES"
else
SUMMARY_ADMINCLASS="NO (missing java compiler)"
-SUMMARY_TCPBW100JAR="NO (missing java compiler)"
SUMMARY_JANALYZEJAR="NO (missing java compiler)"
fi
=======================================
--- /trunk/ndt.spec Fri Jun 20 14:26:21 2014 UTC
+++ /trunk/ndt.spec Wed Jun 25 17:56:39 2014 UTC
@@ -18,12 +18,6 @@
BuildRequires: jansson-devel
BuildRequires: gcc
-%if 0%{?fedora} >= 8
-BuildRequires: java-1.5.0-gcj-devel
-%else
-BuildRequires: java-1.6.0-openjdk-devel
-%endif
-
%description
The Network Diagnostic Tool (NDT) is a client/server program that provides
network configuration and performance testing to a users desktop or laptop
@@ -56,9 +50,9 @@
%build
%if "%{?CERT_FILE}" == ""
-%configure --with-I2util=%{_libdir} --with-fakewww
+%configure --with-I2util=%{_libdir} --enable-fakewww --with-java=precompiled
%else
-%configure --with-I2util=%{_libdir} --with-fakewww --with-cert="%{CERT_FILE}" --with-alias="%{CERT_ALIAS}"
+%configure --with-I2util=%{_libdir} --enable-fakewww --with-java=precompiled --with-cert="%{CERT_FILE}" --with-alias="%{CERT_ALIAS}"
%endif
#make %{?_smp_mflags}
- [ndt-dev] [ndt] r1113 committed - Add a "precompiled" java Applet (signed with an Internet2 signing cert..., ndt, 06/25/2014
Archive powered by MHonArc 2.6.16.