user:yan:aur_repack
This is an old revision of the document!
Table of Contents
Porting rpm/deb package into archlinux enviroment
For some software there is only precompiled package aviable (usually case of commercial one - for example in my case this sw and this sw) and Archlinux is not just as widely used as rpm/deb packaging system based distributions, so package for it is not aviable. Luckily usually it's not so hard to get successful port of package. Here I'll show case-example on MestReNova NMR software.
This method should be avoided when source code is aviable. You should have some really good motive to undergo this. This is usually not the cleanest and safest way how to make a SW package
Unpacking
- bsdtar is capable of unpacking both .rpm and .deb packages, syntax is bsdtar -xf filename. It's also used by makepkg for unpacking source files.
Optimizing
Getting things working
- Package for fedora/RHEL requied selinux in this case - if you have it, maybe good for you. If you don't, than it's unneeded dependency.
- Dependencies sometimes show itself when binary is ran from console. This was case for almost all of dependencies.
- Sometimes running ldd on libraries provided by package helps (was case of one Qt5 library and libglu).
- If you're in dark, trying to look for package dependencies in original package could help, of course usually library in Archlinux is provided under different package compared to for example Debian.
- Don't forget to try functionality, not only if program get started. In my case, program worked until I wanted to zoom for spectra, than it segfaulted (problem was solved by libglu).
Getting things nice
- Make clear archlinux installation.
- Try to get package working under those conditions to identify all crucial dependencies.
Repacking
- It's good to read few makepkg files and don't forget that there is also a wiki page and some man pages too.
- Make a copy of similar makepkg recipe (just some which also goes from precompiled package) and fit it to your case.
- When you're modifying recipe dont forget to keep up with Arch packaging standards especially Directories and Licences
- Usually some desktop inplementation can improve user experience (for example line 18 in this PKGBUILD )
- Clean up everything
- If you're satisfied don't forget how long it took you to get things working. When you upload your PKGBUILD to AUR, you can actually save someone this amount of time.
user/yan/aur_repack.1488955475.txt.gz · Last modified: 2017/03/08 06:44 by yan