]>
Commit | Line | Data |
---|---|---|
c9c0d073 BB |
1 | deb-local: |
2 | @(if test "${HAVE_DPKGBUILD}" = "no"; then \ | |
3 | echo -e "\n" \ | |
4 | "*** Required util ${DPKGBUILD} missing. Please install the\n" \ | |
42f7b73b | 5 | "*** package for your distribution which provides ${DPKGBUILD},\n" \ |
c9c0d073 | 6 | "*** re-run configure, and try again.\n"; \ |
42f7b73b | 7 | exit 1; \ |
c9c0d073 BB |
8 | fi; \ |
9 | if test "${HAVE_ALIEN}" = "no"; then \ | |
10 | echo -e "\n" \ | |
11 | "*** Required util ${ALIEN} missing. Please install the\n" \ | |
42f7b73b | 12 | "*** package for your distribution which provides ${ALIEN},\n" \ |
c9c0d073 | 13 | "*** re-run configure, and try again.\n"; \ |
42f7b73b | 14 | exit 1; \ |
c9c0d073 BB |
15 | fi) |
16 | ||
f3757573 | 17 | deb-kmod: deb-local rpm-kmod |
f3757573 BB |
18 | name=${PACKAGE}; \ |
19 | version=${VERSION}-${RELEASE}; \ | |
20 | arch=`$(RPM) -qp $${name}-kmod-$${version}.src.rpm --qf %{arch} | tail -1`; \ | |
047218e2 | 21 | debarch=`$(DPKG) --print-architecture`; \ |
f3757573 | 22 | pkg1=kmod-$${name}*$${version}.$${arch}.rpm; \ |
047218e2 | 23 | fakeroot $(ALIEN) --bump=0 --scripts --to-deb --target=$$debarch $$pkg1; \ |
f3757573 | 24 | $(RM) $$pkg1 |
8ec27e97 AX |
25 | |
26 | ||
27 | deb-dkms: deb-local rpm-dkms | |
28 | name=${PACKAGE}; \ | |
29 | version=${VERSION}-${RELEASE}; \ | |
30 | arch=`$(RPM) -qp $${name}-dkms-$${version}.src.rpm --qf %{arch} | tail -1`; \ | |
047218e2 | 31 | debarch=`$(DPKG) --print-architecture`; \ |
8ec27e97 | 32 | pkg1=$${name}-dkms-$${version}.$${arch}.rpm; \ |
047218e2 | 33 | fakeroot $(ALIEN) --bump=0 --scripts --to-deb --target=$$debarch $$pkg1; \ |
8ec27e97 | 34 | $(RM) $$pkg1 |
c9c0d073 BB |
35 | |
36 | deb-utils: deb-local rpm-utils | |
37 | name=${PACKAGE}; \ | |
f3757573 | 38 | version=${VERSION}-${RELEASE}; \ |
bd2f5ac9 | 39 | arch=`$(RPM) -qp $${name}-$${version}.src.rpm --qf %{arch} | tail -1`; \ |
047218e2 | 40 | debarch=`$(DPKG) --print-architecture`; \ |
c9c0d073 | 41 | pkg1=$${name}-$${version}.$${arch}.rpm; \ |
ea04106b AX |
42 | pkg2=libnvpair1-$${version}.$${arch}.rpm; \ |
43 | pkg3=libuutil1-$${version}.$${arch}.rpm; \ | |
44 | pkg4=libzfs2-$${version}.$${arch}.rpm; \ | |
45 | pkg5=libzpool2-$${version}.$${arch}.rpm; \ | |
46 | pkg6=libzfs2-devel-$${version}.$${arch}.rpm; \ | |
47 | pkg7=$${name}-test-$${version}.$${arch}.rpm; \ | |
48 | pkg8=$${name}-dracut-$${version}.$${arch}.rpm; \ | |
e10b0808 | 49 | pkg9=$${name}-initramfs-$${version}.$${arch}.rpm; \ |
cae5b340 AX |
50 | ## Arguments need to be passed to dh_shlibdeps. Alien provides no mechanism |
51 | ## to do this, so we install a shim onto the path which calls the real | |
52 | ## dh_shlibdeps with the required arguments. | |
53 | path_prepend=`mktemp -d /tmp/intercept.XXX`; \ | |
54 | echo "#$(SHELL)" > $${path_prepend}/dh_shlibdeps; \ | |
55 | echo "`which dh_shlibdeps` -- \ | |
56 | -xlibuutil1linux -xlibnvpair1linux -xlibzfs2linux -xlibzpool2linux" \ | |
57 | >> $${path_prepend}/dh_shlibdeps; \ | |
58 | ## These -x arguments are passed to dpkg-shlibdeps, which exclude the | |
59 | ## Debianized packages from the auto-generated dependencies of the new debs, | |
60 | ## which should NOT be mixed with the alien-generated debs created here | |
61 | chmod +x $${path_prepend}/dh_shlibdeps; \ | |
62 | env PATH=$${path_prepend}:$${PATH} \ | |
047218e2 | 63 | fakeroot $(ALIEN) --bump=0 --scripts --to-deb --target=$$debarch \ |
e10b0808 | 64 | $$pkg1 $$pkg2 $$pkg3 $$pkg4 $$pkg5 $$pkg6 $$pkg7 \ |
cae5b340 AX |
65 | $$pkg8 $$pkg9; \ |
66 | $(RM) $${path_prepend}/dh_shlibdeps; \ | |
67 | rmdir $${path_prepend}; \ | |
e10b0808 AX |
68 | $(RM) $$pkg1 $$pkg2 $$pkg3 $$pkg4 $$pkg5 $$pkg6 $$pkg7 \ |
69 | $$pkg8 $$pkg9; | |
c9c0d073 | 70 | |
8ec27e97 | 71 | deb: deb-kmod deb-dkms deb-utils |