Re: [PATCH libvirt-java] Add debian packaging for the Java bindings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 07/19/2012 07:33 PM, Wido den Hollander wrote:
Signed-off-by: Wido den Hollander <wido@xxxxxxxxx>
---
  build.xml         |   19 +++++++++++++++++++
  debian/control.in |    9 +++++++++
  2 files changed, 28 insertions(+)
  create mode 100644 debian/control.in

diff --git a/build.xml b/build.xml
index 606cdaa..eefd08c 100644
--- a/build.xml
+++ b/build.xml
@@ -7,6 +7,9 @@
  	<property name="src.file" value="target/${src}.tar.gz" />
  	<property name="spec" value="libvirt-java.spec" />
  	<property name="spec.file" value="target/${spec}" />
+	<property name="debian.pkgdir" value="target/libvirt-java" />
+	<property name="debian.controlfile" value="${debian.pkgdir}/DEBIAN/control" />
+	<property name="debian.pkg" value="target/libvirt-java_${version}_all.deb" />

  	<path id="compile.classpath">
  		<fileset dir="${jar.dir}">
@@ -69,6 +72,22 @@
  		</copy>
  	</target>

+	<target name="deb" depends="build" description="build a debian Debian package">
+		<mkdir dir="${debian.pkgdir}/DEBIAN" />
+		<copy file="debian/control.in" tofile="${debian.controlfile}" overwrite="true" filtering="true">
+			<filterset filtersfile="build.properties" />
+		</copy>
+
+		<mkdir dir="${debian.pkgdir}/${jar.dir}" />
+		<copy file="${jar.file}" todir="${debian.pkgdir}/${jar.dir}" />
+		<symlink link="${debian.pkgdir}/${jar.dir}/libvirt.jar" resource="${jar.dir}/${jar}.jar" overwrite="true" />
+		<exec executable="dpkg-deb">
+			<arg value="-b" />
+			<arg value="${debian.pkgdir}" />
+			<arg value="${debian.pkg}" />
+		</exec>
+	</target>
+
  	<target name="package" depends="src,build,docs,spec" description="builds the rpms">
  		<copy file="${src.file}" todir="${rpm.topdir}/SOURCES" />
  		<copy file="${spec.file}" todir="${rpm.topdir}/SPECS" />
diff --git a/debian/control.in b/debian/control.in
new file mode 100644
index 0000000..06ab6d8
--- /dev/null
+++ b/debian/control.in
@@ -0,0 +1,9 @@
+Homepage: http://libvirt.org/java.html
+Maintainer: Wido den Hollander <wido@xxxxxxxxx>
+Section: java
+Priority: optional
+Version: @version@
+Package: libvirt-java
+Architecture: all
+Depends: libjna-java (>= 3.2.4), libvirt0 (>= 0.9.8)
+Description: These Java bindings expose the C API in a Java friendly way


Did somebody get a chance yet to take a look at this patch?

Thanks,

Wido

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]