tag 477565 + patch
thanks

On Wed, Dec 14, 2011 at 01:34:08AM +0400, Dmitry Eremin-Solenikov wrote:
> Package: device-tree-compiler
> Version: 1.3.0-1
> Followup-For: Bug #477565
> Tag: patch
> 
> Hi,
> 
> Please care to apply the provided patch that enables packaging of libfdt
> into separate libfdt-dev package.
>

Thanks for your patch. While it is true that libfdt was not having a
stable API/ABI, latest upstream version fixed that. Now the shared
library is properly versioned, so it's possible to provide it in a
package.

It's what the patch below does, it also provide a few more useful
binaries. It uses dh_install, as installing more than 5 or 6 files by
hand is a pain.

diff -u device-tree-compiler-1.3.0/debian/control 
device-tree-compiler-1.3.0/debian/control
--- device-tree-compiler-1.3.0/debian/control
+++ device-tree-compiler-1.3.0/debian/control
@@ -13,4 +13,20 @@
-Depends: ${shlibs:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}
 Description: OpenFirmware Device Tree Compiler for Flat Device Trees
  This tool compiles device-tree descriptions for booting PowerPC
  kernels on embedded systems without OpenFirmware.
+
+Package: libfdt1
+Architecture: any
+Section: libs
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: Flat Device Trees manipulation library
+ This is a library containing functions for manipulating Flat Device Trees.
+
+Package: libfdt-dev
+Architecture: any
+Section: libdevel
+Depends: libfdt1 (= ${binary:Version}), ${misc:Depends}
+Description: Flat Device Trees manipulation library - development files
+ This is a library containing functions for manipulating Flat Device Trees.
+ .
+ This package contains the files needed for development against libfdt.
diff -u device-tree-compiler-1.3.0/debian/rules 
device-tree-compiler-1.3.0/debian/rules
--- device-tree-compiler-1.3.0/debian/rules
+++ device-tree-compiler-1.3.0/debian/rules
@@ -40,7 +40,8 @@
        dh_testroot
        dh_prep
        dh_installdirs
-       install -m755 dtc $(CURDIR)/debian/device-tree-compiler/usr/bin
+       $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp PREFIX=/usr
+       dh_install --list-missing --sourcedir=debian/tmp
        touch install-stamp
 
 # Build architecture-independent files here.
@@ -59,6 +60,7 @@
        dh_strip
        dh_compress
        dh_fixperms
+       dh_makeshlibs
        dh_installdeb
        dh_shlibdeps
        dh_gencontrol
--- device-tree-compiler-1.3.0.orig/debian/device-tree-compiler.install
+++ device-tree-compiler-1.3.0/debian/device-tree-compiler.install
@@ -0,0 +1 @@
+usr/bin/*
--- device-tree-compiler-1.3.0.orig/debian/libfdt1.install
+++ device-tree-compiler-1.3.0/debian/libfdt1.install
@@ -0,0 +1,2 @@
+usr/lib/libfdt-*.so
+usr/lib/libfdt.so.*
--- device-tree-compiler-1.3.0.orig/debian/libfdt-dev.install
+++ device-tree-compiler-1.3.0/debian/libfdt-dev.install
@@ -0,0 +1,3 @@
+usr/include/*
+usr/lib/libfdt.a
+usr/lib/libfdt.so



-- 
Aurelien Jarno                          GPG: 1024D/F1BCDB73
[email protected]                 http://www.aurel32.net



-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to