User Tools

Site Tools


user:yan:aur_repack

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
user:yan:aur_repack [2017/02/08 19:28] – created yanuser:yan:aur_repack [2018/04/30 05:02] (current) – [Porting rpm/deb package into archlinux enviroment] yan
Line 1: Line 1:
 ===== Porting rpm/deb package into archlinux enviroment ===== ===== 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 [[http://example.com|this sw]] and [[https://aur.archlinux.org/packages/mestrenova/| this sw]]) and [[https://www.archlinux.org/|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 [[http://mestrelab.com/software/mnova/|MestReNova]] NMR software.+For some software there is only precompiled package available (usually the case of commercial ones - for example in the my case [[https://aur.archlinux.org/packages/mestrenova/| this sw]]). But, the [[https://www.archlinux.org/|Archlinux]] is not as widely used distribution as the rpm/deb packaging system based distributions. This means that the package for the Archlinux is sometimes unavailable as it is in my case. Luckilyit's not so hard to get successful port of the package. I've performed a case-example of this on the [[http://mestrelab.com/software/mnova/|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 **+** This method should be avoided when the source code is available. You should have some really good motive to undergo this. Keep in mind that this is not the cleanest and the safest way how to make a SW package**
  
 ===== Unpacking ===== ===== 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.+  * **bsdtar** is capable of unpacking both the .rpm and the .deb packages, syntax is **bsdtar -xf filename**. It's also used by makepkg for unpacking source files.
  
 ===== Optimizing ===== ===== Optimizing =====
Line 12: Line 12:
   * 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.   * 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.   * Dependencies sometimes show itself when binary is ran from console. This was case for almost all of dependencies.
-  * **[[https://linux.die.net/man/1/ldd | ldd]]** comes pretty handy when program is not so communicative.+  * **[[https://linux.die.net/man/1/ldd | ldd]]** comes pretty handy when program is not so communicative. [[https://strace.io/|strace]] can be used when things get nasty.
   * Sometimes running ldd on libraries provided by package helps (was case of one Qt5 library and libglu).   * 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.   * 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).+  * Don't forget to try the functionality, not only if the program gets started. In my case, the program worked until I wanted to zoom spectrum, than it segfaulted (problem was solved by the libglu library).
  
 == Getting things nice == == Getting things nice ==
-  * Make clear archlinux installation. +  * Make clear archlinux installation. 
-  * Try to get package working under those conditions to identify all crucial dependencies.+  * Try to get the package working under those conditions to identify all the crucial dependencies.
  
 ===== Repacking ===== ===== Repacking =====
-  * It's good to read few makepkg files and don't forget that [[https://wiki.archlinux.org/index.php/Creating_packages | there is also a wiki page ]] and some man pages too. +  * It's good to read few makepkg files and don't forget that [[https://wiki.archlinux.org/index.php/Creating_packages | 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.+  * 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 [[https://wiki.archlinux.org/index.php/Arch_packaging_standards | Arch packaging standards]] especially [[https://wiki.archlinux.org/index.php/Arch_packaging_standards#Directories | Directories]] and [[https://wiki.archlinux.org/index.php/Arch_packaging_standards#Licenses | Licences]]   * When you're modifying recipe dont forget to keep up with [[https://wiki.archlinux.org/index.php/Arch_packaging_standards | Arch packaging standards]] especially [[https://wiki.archlinux.org/index.php/Arch_packaging_standards#Directories | Directories]] and [[https://wiki.archlinux.org/index.php/Arch_packaging_standards#Licenses | Licences]]
   * Usually some desktop inplementation can improve user experience (for example line 18 in [[https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=mestrenova | this PKGBUILD ]] )   * Usually some desktop inplementation can improve user experience (for example line 18 in [[https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=mestrenova | this PKGBUILD ]] )
   * Clean up everything   * 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 [[https://aur.archlinux.org/ | AUR]], you can actually save someone this amount of time.   * If you're satisfied don't forget how long it took you to get things working. When you upload your PKGBUILD to [[https://aur.archlinux.org/ | AUR]], you can actually save someone this amount of time.
user/yan/aur_repack.1486582137.txt.gz · Last modified: 2017/02/08 19:28 by yan