0

I tried to compile and package snownews and deadbeef to DEB files for my Raspberry Pi OS:

sudo auto-apt ./configure
sudo checkinstall

And it's failed. Here is the result it returns:

From snownews

========================= Installation results ===========================
Installing /usr/local/share/man/man1/snownews.1 ...
install: cannot create directory '/usr/local/share/man': No such file or directory
make: *** [man/Module.mk:18: /usr/local/share/man/man1/snownews.1] Error 1

****  Installation failed. Aborting package creation.

Cleaning up...OK

Bye.

From deadbeef

========================= Installation results ===========================
Making install in pixmaps
make[1]: Entering directory '/home/pi/Downloads/deadbeef-1.8.4/pixmaps'
make[2]: Entering directory '/home/pi/Downloads/deadbeef-1.8.4/pixmaps'
make[2]: Nothing to be done for 'install-exec-am'.
 /bin/mkdir -p '/usr/local/share/deadbeef/pixmaps'
/bin/mkdir: cannot create directory ‘/usr/local/share/deadbeef’: No such file or directory
make[2]: *** [Makefile:455: install-pixmapsDATA] Error 1
make[2]: Leaving directory '/home/pi/Downloads/deadbeef-1.8.4/pixmaps'
make[1]: *** [Makefile:524: install-am] Error 2
make[1]: Leaving directory '/home/pi/Downloads/deadbeef-1.8.4/pixmaps'
make: *** [Makefile:822: install-recursive] Error 1

****  Installation failed. Aborting package creation.

Cleaning up...OK

Bye.

I tried to Google the error message, however it is too vague that I couldn't get the answer I need. It only said that it couldn't create directory. But I have run with the highest privilege (sudo) and it still said it couldn't? I don't really know what to do next.

My main goal is package the software so I can manage it with apt. The reason I would like it is because I don't know if the next update of the software requires me to remove the old version or not. So I try my best to keep everything as neat as possible.

So far what I did/knew:

  1. The source dir is in my home dir.
  2. sudo was used during the compiling process
  3. deadbeef source was compiled for ARMHF once, so I'm pretty sure that the source supports this architecture.
  4. snownews is unsure.
  5. I have success compiling & packaging alpine software. So I don't think this is the checkinstall fault.
  • deb files is normally installed with sudo dpkg -i /path/to/deb/file and then sudo apt-get install -f alternative with sudo apt install ./name.deb . Have you tried that? – Mats Karlsson Sep 10 at 13:22
  • The complaints are that a directory does not exist. Do they exist? What does ls /usr/local/share produce? Do the compiles go through after you've mkdir -p /usr/local/share/man/man1? – Ljm Dullaart Sep 10 at 15:20
  • @LjmDullaart with ls /usr/local/share it produces ca-certificates fonts. And when I created the dir, it passed but... it still kept printing dir error with a new dir path (/usr/local/share/man/de). So I don't think this could solve the problem because I don't exactly know how many dirs it need to create. (Shouldn't it be able to create programtically?) – ngdangtu Sep 10 at 17:49
  • @MatsKarlsson I think you get wrong idea. My case was I have no deb package, so I need to compile sources to deb packages. And I couldn't do that because the cannot create directory error. – ngdangtu Sep 10 at 17:51
  • The problem is, that the creator of the program/package/... has apparently a number of directories on his machine and doesn't bother to verify that those directories are available during the config-phase. Happens a lot. So, yes, that can be seen as a bug in the creation of the package. However, the number of directories that are used should be limited, so you should be able, in just a few runs, to create all of them. Your other option is to contact the creator/maintainer and wait until he releases an updated package. – Ljm Dullaart Sep 10 at 21:25
0

In any sane world, these commands will compile and package snownews:

First install debmake and package specific dependencies:

sudo apt-get -y install debmake
sudo apt-get -y install libxml2-dev libncurses-dev zlib1g-dev

Retrieve the latest master branch from github and rename it with a numeric version number (today's date is OK):

wget https://github.com/kouya/snownews/archive/master.tar.gz
tar zxf master.tar.gz
mv snownews-master snownews-20200915
tar zcf snownews-20200915.tar.gz snownews-20200915
rm master.tar.gz

Debianize the package:

cd snownews-20200915
debmake
debuild

However, this fails in the debuild step because the Makefile installs files in non-standard places or ignores the DESTDIR environment variable that debuild uses to install the package under a temporary directory. It's an exercise for the reader to fix the configuration that causes this (and send a pull request to the original author).

| improve this answer | |

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.