[pkg-java] r5227 - in trunk/jclassinfo: . debian debian/patches

fourmond at alioth.debian.org fourmond at alioth.debian.org
Sat Dec 29 15:55:47 UTC 2007


Author: fourmond
Date: 2007-12-29 15:55:47 +0000 (Sat, 29 Dec 2007)
New Revision: 5227

Added:
   trunk/jclassinfo/debian/
   trunk/jclassinfo/debian/README.Debian
   trunk/jclassinfo/debian/changelog
   trunk/jclassinfo/debian/compat
   trunk/jclassinfo/debian/control
   trunk/jclassinfo/debian/copyright
   trunk/jclassinfo/debian/dirs
   trunk/jclassinfo/debian/docs
   trunk/jclassinfo/debian/manpages
   trunk/jclassinfo/debian/patches/
   trunk/jclassinfo/debian/patches/00list
   trunk/jclassinfo/debian/patches/01-make-static-lib.dpatch
   trunk/jclassinfo/debian/patches/02-use-stdin.dpatch
   trunk/jclassinfo/debian/rules
   trunk/jclassinfo/debian/watch
Log:
[svn-inject] Applying Debian modifications to trunk


Property changes on: trunk/jclassinfo/debian
___________________________________________________________________
Name: mergeWithUpstream
   + 1

Added: trunk/jclassinfo/debian/README.Debian
===================================================================
--- trunk/jclassinfo/debian/README.Debian	                        (rev 0)
+++ trunk/jclassinfo/debian/README.Debian	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,12 @@
+jclassinfo for Debian
+---------------------
+
+The original tarball provides a libjclass shared library. As I didn't
+think there would be much use for it, I preferred, for the sake of
+simplicity, to turn it into a statically linked library embedded
+in the jclassinfo binary.
+
+If you want to work with the library, please file a bug report against this
+package.
+
+ -- Vincent Fourmond <fourmond at debian.org>, Fri, 28 Dec 2007 10:54:46 +0100

Added: trunk/jclassinfo/debian/changelog
===================================================================
--- trunk/jclassinfo/debian/changelog	                        (rev 0)
+++ trunk/jclassinfo/debian/changelog	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,9 @@
+jclassinfo (0.19.1-1) unstable; urgency=low
+
+  * Initial release (Closes: #458062)
+  * 01-make-static-lib to link libjclass statically
+  * 02-use-stdin to have "-" work with the usual meaning
+    as an argument (this way, no need for temporary files for jar analysis).
+
+ -- Vincent Fourmond <fourmond at debian.org>  Fri, 28 Dec 2007 10:18:32 +0100
+

Added: trunk/jclassinfo/debian/compat
===================================================================
--- trunk/jclassinfo/debian/compat	                        (rev 0)
+++ trunk/jclassinfo/debian/compat	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1 @@
+5

Added: trunk/jclassinfo/debian/control
===================================================================
--- trunk/jclassinfo/debian/control	                        (rev 0)
+++ trunk/jclassinfo/debian/control	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,20 @@
+Source: jclassinfo
+Section: devel
+Priority: optional
+Maintainer: Vincent Fourmond <fourmond at debian.org>
+Build-Depends: debhelper (>= 5), automake, autoconf, 
+ autotools-dev, dpatch, libtool, zlib1g-dev
+Standards-Version: 3.7.3
+Homepage: http://jclassinfo.sourceforge.net/
+
+Package: jclassinfo
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: extracts information from Java class files
+ jclassinfo reads Java class files and extract useful information
+ from them, such as:
+   * the classes/methods/constants/fields provided
+   * their dependencies
+   * the version of the virtual machine necessary to run them
+   * a full disassembly of the bytecode
+   * other attributes

Added: trunk/jclassinfo/debian/copyright
===================================================================
--- trunk/jclassinfo/debian/copyright	                        (rev 0)
+++ trunk/jclassinfo/debian/copyright	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,35 @@
+This package was debianized by Vincent Fourmond <fourmond at debian.org> on
+Fri, 28 Dec 2007 10:18:32 +0100.
+
+It was downloaded from <url:http://sourceforge.net/project/showfiles.php?group_id=74004>
+
+Upstream Author: 
+
+    Nicos Panayides <anarxia at gmx.net>
+
+Copyright: 
+
+    Copyright 2003, Nicos Panayides
+
+License:
+
+    This package is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+ 
+    This package is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+ 
+    You should have received a copy of the GNU General Public License
+    along with this package; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL'.
+
+The Debian packaging is (C) 2007, Vincent Fourmond <fourmond at debian.org> and
+is licensed under the GPL, see above.
+

Added: trunk/jclassinfo/debian/dirs
===================================================================
--- trunk/jclassinfo/debian/dirs	                        (rev 0)
+++ trunk/jclassinfo/debian/dirs	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1 @@
+usr/bin

Added: trunk/jclassinfo/debian/docs
===================================================================
--- trunk/jclassinfo/debian/docs	                        (rev 0)
+++ trunk/jclassinfo/debian/docs	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,4 @@
+NEWS
+README
+README.win32
+TODO

Added: trunk/jclassinfo/debian/manpages
===================================================================
--- trunk/jclassinfo/debian/manpages	                        (rev 0)
+++ trunk/jclassinfo/debian/manpages	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1 @@
+jclassinfo.1
\ No newline at end of file

Added: trunk/jclassinfo/debian/patches/00list
===================================================================
--- trunk/jclassinfo/debian/patches/00list	                        (rev 0)
+++ trunk/jclassinfo/debian/patches/00list	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,2 @@
+01-make-static-lib
+02-use-stdin

Added: trunk/jclassinfo/debian/patches/01-make-static-lib.dpatch
===================================================================
--- trunk/jclassinfo/debian/patches/01-make-static-lib.dpatch	                        (rev 0)
+++ trunk/jclassinfo/debian/patches/01-make-static-lib.dpatch	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,19 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 01-make-static-lib.dpatch by  <fourmond at debian.org>
+##
+## DP: Link statically libjclass: we don't want to support a shared library
+## DP: with dubious utility.
+
+ at DPATCH@
+diff -urNad jclassinfo-0.19.1~/jclass/Makefile.am jclassinfo-0.19.1/jclass/Makefile.am
+--- jclassinfo-0.19.1~/jclass/Makefile.am	2004-03-23 05:55:15.000000000 +0100
++++ jclassinfo-0.19.1/jclass/Makefile.am	2007-12-28 10:43:47.000000000 +0100
+@@ -3,7 +3,7 @@
+ INCLUDES=
+ 
+ lib_LTLIBRARIES = libjclass.la
+-libjclass_la_LDFLAGS = -no-undefined -version-info @JCLASS_CURRENT@:@JCLASS_RELEASE@:@JCLASS_AGE@
++libjclass_la_LDFLAGS = -no-undefined -version-info @JCLASS_CURRENT@:@JCLASS_RELEASE@:@JCLASS_AGE@ -static
+ 
+ library_includedir=$(includedir)/jclass/jclass
+ 


Property changes on: trunk/jclassinfo/debian/patches/01-make-static-lib.dpatch
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/jclassinfo/debian/patches/02-use-stdin.dpatch
===================================================================
--- trunk/jclassinfo/debian/patches/02-use-stdin.dpatch	                        (rev 0)
+++ trunk/jclassinfo/debian/patches/02-use-stdin.dpatch	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,187 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 02-use-stdin.dpatch by  <fourmond at debian.org>
+##
+## DP: Adds some code so that the "-" argument for stdin works.
+
+ at DPATCH@
+diff -urNad jclassinfo-0.19.1~/jclass/Makefile.am jclassinfo-0.19.1/jclass/Makefile.am
+--- jclassinfo-0.19.1~/jclass/Makefile.am	2007-12-28 18:41:58.000000000 +0100
++++ jclassinfo-0.19.1/jclass/Makefile.am	2007-12-28 18:41:58.000000000 +0100
+@@ -29,8 +29,9 @@
+ 	constant_pool.c \
+ 	field.c \
+ 	jar.c \
+-    java_file.c \
++	java_file.c \
+ 	java_buf.c \
+ 	jstring.c \
+ 	manifest.c \
++	open.h open.c \
+ 	strtok_r.h strtok_r.c
+diff -urNad jclassinfo-0.19.1~/jclass/class.c jclassinfo-0.19.1/jclass/class.c
+--- jclassinfo-0.19.1~/jclass/class.c	2004-05-07 13:44:44.000000000 +0200
++++ jclassinfo-0.19.1/jclass/class.c	2007-12-28 18:41:58.000000000 +0100
+@@ -28,6 +28,8 @@
+ #include <jclass/jstring.h>
+ #include <jclass/class_loader.h>
+ 
++#include <jclass/open.h>
++
+ /*
+ *
+ * libjclass API reference
+@@ -74,7 +76,7 @@
+ 	if(filename == NULL)
+ 		return NULL;
+ 	
+-	is_filename = (strlen(filename) > 6) && !strcmp(".class", &filename[strlen(filename) - 6]);
++	is_filename = ((strlen(filename) > 6) && !strcmp(".class", &filename[strlen(filename) - 6]) || (!strcmp(filename, "-")));
+ 	
+ 	if(!is_filename)
+ 	{		
+@@ -96,7 +98,7 @@
+ 	}
+ 	else
+ 	{
+-		classfile = fopen(filename, "rb");	
++		classfile = my_open(filename, "rb");	
+ 		new_class = jclass_class_new_from_file(classfile);
+ 	}
+ 	
+diff -urNad jclassinfo-0.19.1~/jclass/class_loader.c jclassinfo-0.19.1/jclass/class_loader.c
+--- jclassinfo-0.19.1~/jclass/class_loader.c	2004-07-10 17:15:10.000000000 +0200
++++ jclassinfo-0.19.1/jclass/class_loader.c	2007-12-28 18:41:58.000000000 +0100
+@@ -40,6 +40,8 @@
+ #include <jclass/jstring.h>
+ #include <jclass/jar.h>
+ 
++#include <jclass/open.h>
++
+ #include "strtok_r.h"
+ 
+ #ifdef __WIN32__
+@@ -212,7 +214,7 @@
+ 			absolute_class_filename[path_len + 1] = '\0';
+ 			strcat(absolute_class_filename, class_filename);
+ 	
+-			file_ptr = fopen(absolute_class_filename,"rb");
++			file_ptr = my_open(absolute_class_filename,"rb");
+ 			if (file_ptr) {
+ 				fclose(file_ptr);
+ 				break;
+@@ -292,7 +294,7 @@
+ 			absolute_class_filename[path_len + 1] = '\0';
+ 			strcat(absolute_class_filename, class_filename);
+ 	
+-			class_file_info->file_ptr = fopen(absolute_class_filename,"rb");
++			class_file_info->file_ptr = my_open(absolute_class_filename,"rb");
+ 			free(absolute_class_filename);
+ 			if(class_file_info->file_ptr != NULL)
+ 				break;
+diff -urNad jclassinfo-0.19.1~/jclass/jar.c jclassinfo-0.19.1/jclass/jar.c
+--- jclassinfo-0.19.1~/jclass/jar.c	2004-03-21 06:04:10.000000000 +0100
++++ jclassinfo-0.19.1/jclass/jar.c	2007-12-28 18:41:58.000000000 +0100
+@@ -38,6 +38,8 @@
+ #include <zlib.h>
+ #include <jclass/jar.h>
+ 
++#include <jclass/open.h>
++
+ static int readcompresszip(JarFile*, const JarEntry*, char*);
+ static int seekcompresszip (JarFile*, const JarEntry*);
+ static uint16_t read_word (char*);
+@@ -211,7 +213,7 @@
+ 	JarFile *zip = (JarFile *) malloc (sizeof (JarFile));
+ 
+ 	/* open */
+-	zip->fp = fopen (zipfile, "rb");
++	zip->fp = my_open (zipfile, "rb");
+ 	if (zip->fp == NULL)
+ 	{
+ 		free (zip);
+diff -urNad jclassinfo-0.19.1~/jclass/open.c jclassinfo-0.19.1/jclass/open.c
+--- jclassinfo-0.19.1~/jclass/open.c	1970-01-01 01:00:00.000000000 +0100
++++ jclassinfo-0.19.1/jclass/open.c	2007-12-28 18:41:58.000000000 +0100
+@@ -0,0 +1,32 @@
++/* open.c: a small wrapper around fopen to take care of "-"
++   Copyright 2007 by Vincent Fourmond
++
++   This program is free software; you can redistribute it and/or
++   modify it under the terms of the GNU General Public License
++   as published by the Free Software Foundation; either version 2
++   of the License, or (at your option) any later version.
++   *
++   This program is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++   GNU General Public License for more details.
++ 
++   You should have received a copy of the GNU General Public License
++   along with this program; if not, write to the Free Software
++   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
++
++*/
++
++#include <stdio.h>
++#include <string.h>
++
++FILE * my_open(const char * file, const char * mode)
++{
++  if(! strcmp(file, "-")) {
++    if(strchr(mode, 'r')) 	/* Read mode */
++      return fdopen(0, "r");
++    else
++      return fdopen(1, "w");
++  }
++  return fopen(file, mode);
++}
+diff -urNad jclassinfo-0.19.1~/jclass/open.h jclassinfo-0.19.1/jclass/open.h
+--- jclassinfo-0.19.1~/jclass/open.h	1970-01-01 01:00:00.000000000 +0100
++++ jclassinfo-0.19.1/jclass/open.h	2007-12-28 18:41:58.000000000 +0100
+@@ -0,0 +1,20 @@
++/* open.h: a small wrapper around fopen to take care of "-"
++   Copyright 2007 by Vincent Fourmond
++
++   This program is free software; you can redistribute it and/or
++   modify it under the terms of the GNU General Public License
++   as published by the Free Software Foundation; either version 2
++   of the License, or (at your option) any later version.
++   *
++   This program is distributed in the hope that it will be useful,
++   but WITHOUT ANY WARRANTY; without even the implied warranty of
++   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++   GNU General Public License for more details.
++ 
++   You should have received a copy of the GNU General Public License
++   along with this program; if not, write to the Free Software
++   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
++
++*/
++
++FILE * my_open(const char * file, const char * mode);
+diff -urNad jclassinfo-0.19.1~/jclassinfo.1 jclassinfo-0.19.1/jclassinfo.1
+--- jclassinfo-0.19.1~/jclassinfo.1	2004-05-07 13:49:00.000000000 +0200
++++ jclassinfo-0.19.1/jclassinfo.1	2007-12-28 18:43:10.000000000 +0100
+@@ -1,4 +1,4 @@
+-.TH "jclassinfo" "1" "0.18" "jclassinfo" "utils"
++.TH "jclassinfo" "1" "0.19" "jclassinfo" "utils"
+ .SH "NAME"
+ .LP 
+ jclassinfo \- Provides information for Java class files.
+@@ -8,7 +8,15 @@
+ 
+ .SH "DESCRIPTION"
+ .LP 
+-jclassinfo reads a class file and provides all sorts of information about it.
++jclassinfo reads a class file and provides all sorts of information
++about it. 
++.I file
++can be 
++.I -
++then
++.B jclassinfo
++reads a classfile from standard input.
++
+ .SH "OPTIONS"
+ .LP 
+ .TP 


Property changes on: trunk/jclassinfo/debian/patches/02-use-stdin.dpatch
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/jclassinfo/debian/rules
===================================================================
--- trunk/jclassinfo/debian/rules	                        (rev 0)
+++ trunk/jclassinfo/debian/rules	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,89 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was added by Craig Small in version 0.37 of dh-make.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+
+# These are used for cross-compiling and for saving the configure script
+# from having to guess our platform (since we know it already)
+DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+include /usr/share/dpatch/dpatch.make
+
+config.status: configure patch-stamp
+	dh_testdir
+	# Add here commands to configure the package.
+ifneq "$(wildcard /usr/share/misc/config.sub)" ""
+	cp -f /usr/share/misc/config.sub config.sub
+endif
+ifneq "$(wildcard /usr/share/misc/config.guess)" ""
+	cp -f /usr/share/misc/config.guess config.guess
+endif
+	aclocal
+	automake
+	autoconf
+	./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info CFLAGS="$(CFLAGS)" LDFLAGS="-Wl,-z,defs"
+
+
+build: build-stamp
+
+build-stamp: patch-stamp config.status
+	dh_testdir
+
+	# Add here commands to compile the package.
+	$(MAKE)
+
+	touch $@
+
+clean: clean-patched unpatch
+clean-patched:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp 
+
+	# Add here commands to clean up after the build process.
+	[ ! -r Makefile ] || $(MAKE) distclean
+	rm -f config.sub config.guess
+
+	dh_clean 
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k 
+	dh_installdirs
+
+	# Add here commands to install the package into debian/jclassinfo.
+	cd jclassinfo && $(MAKE) DESTDIR=$(CURDIR)/debian/jclassinfo install
+	cd xml && $(MAKE) DESTDIR=$(CURDIR)/debian/jclassinfo install
+
+
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs ChangeLog
+	dh_installdocs
+	dh_installman
+	dh_strip
+	dh_compress
+	dh_fixperms
+	dh_installdeb
+	dh_shlibdeps
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install 


Property changes on: trunk/jclassinfo/debian/rules
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/jclassinfo/debian/watch
===================================================================
--- trunk/jclassinfo/debian/watch	                        (rev 0)
+++ trunk/jclassinfo/debian/watch	2007-12-29 15:55:47 UTC (rev 5227)
@@ -0,0 +1,12 @@
+# Example watch control file for uscan
+# Rename this file to "watch" and then you can run the "uscan" command
+# to check for upstream updates and more.
+# See uscan(1) for format
+
+# Compulsory line, this is a version 3 file
+version=3
+
+# Uncomment to find new files on sourceforge, for debscripts >= 2.9
+http://sf.net/jclassinfo/jclassinfo-(.*)\.tar\.gz
+
+




More information about the pkg-java-commits mailing list