1

This is my first attempt to create own package from sources. How I did it:

fakeroot
make install DESTDIR=/home/user/temp
cd /home/user/temp
mkdir DEBIAN
find etc | sed "s/^/\//" > DEBIAN/conffiles

After that I created DEBIAN/control file and run dpkg -b /home/user/temp. After that I have deb package and as a real root I do dpkg -i /home/user/temp.deb. However, dpkg doesn't copy files from deb package to fs but it complains that such folders don't exist ( No such file or directory). As I understand it must create folders as they are in DEBIAN/CONTENTS but it doesn't. What do I miss?

EDIT I tried to add file DEBIAN/dirs with list of paths:

/etc
/etc/selinux/
/etc/selinux/refpolicy
...

But it didn't help ( I tried with leading / and without leading /)

EDIT Command dpkg-deb -c temp.deb has the following output

drwxr-xr-x user/user       0 2016-09-08 10:57 ./
drwxr-xr-x user/user       0 2016-09-08 10:57 ./etc/
drwxr-xr-x user/user       0 2016-09-08 10:57 ./etc/selinux/
drwxr-xr-x user/user       0 2016-09-08 10:57 ./etc/selinux/refpolicy/
drwxr-xr-x user/user       0 2016-09-08 10:57 ./etc/selinux/refpolicy/src/
drwxr-xr-x user/user       0 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/
drwxr-xr-x user/user       0 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/support/
-rw-r--r-- user/user    6176 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/support/Makefile.devel
-rw-r--r-- user/user       6 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/support/undivert.m4
-rw-r--r-- user/user      12 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/support/divert.m4
-rw-r--r-- user/user   10673 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/support/pyplate.py
-rw-r--r-- user/user   13796 2016-09-08 10:57 ./etc/selinux/refpolicy/src/policy/support/fc_sort.c
..... etc

And here what I get:

error creating directory `./etc/selinux/refpolicy/src': No such file or directory
  • What does the package contain? dpkg-deb -c temp.deb will tell you... – Stephen Kitt Sep 8 '16 at 9:20
  • @Stephen Kitt I edited the question. – Pavel Sep 8 '16 at 9:24
  • @Stephen Kitt Not a hint? – Pavel Sep 9 '16 at 5:58
  • I haven't figured out what could be going wrong... I can write an answer explaining how you should go about packaging, but that won't explain the dpkg error. – Stephen Kitt Sep 9 '16 at 6:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.