Please don’t use packer. It is out dated and discontinued. Use Yay AUR helper instead. https://ostechnix.com/yay-found-yet-another-reliable-aur-helper/
A while ago, we wrote an article about how to install Yaourt in Arch Linux. Yaourt is a pacman wrapper that can be used to install packages from AUR. For those who don't know about AUR, It is a community driven repository that contains 44,000+ packages. Today, in this tutorial, we will discuss another Pacman front-end called Packer. Packer is a wrapper for both Pacman and AUR. Like Yaourt, Packer will also reduce the complexity of manually compiling and installing the packages. It allows you to install, update, search, and show information for any package in the main repositories and in the AUR. For other commands, such as removing packages, use pacman.
In this brief tutorial, let us see how to install and use Packer in Arch Linux.
Install Packer on Arch Linux
First, install the required dependencies using command:
$ sudo pacman -S base-devel fakeroot jshon expac git wget
:: There are 25 members in group base-devel: :: Repository core 1) autoconf 2) automake 3) binutils 4) bison 5) fakeroot 6) file 7) findutils 8) flex 9) gawk 10) gcc 11) gettext 12) grep 13) groff 14) gzip 15) libtool 16) m4 17) make 18) pacman 19) patch 20) pkg-config 21) sed 22) sudo 23) texinfo 24) util-linux 25) which Enter a selection (default=all):
Download the PKGBUILD script from AUR:
$ wget https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=packer
Rename the downloaded file:
$ mv PKGBUILD\?h\=packer PKGBUILD
Now, run the following command to compile the downloaded package:
==> Making package: packer 20150808-1 (Tue May 10 18:39:36 IST 2016) ==> Checking runtime dependencies... ==> Checking buildtime dependencies... ==> Retrieving sources... -> Cloning packer git repo... Cloning into bare repository '/home/sk/packer'... remote: Counting objects: 1505, done. remote: Compressing objects: 100% (5/5), done. remote: Total 1505 (delta 0), reused 0 (delta 0), pack-reused 1500 Receiving objects: 100% (1505/1505), 398.25 KiB | 204.00 KiB/s, done. Resolving deltas: 100% (530/530), done. Checking connectivity... done. ==> Validating source files with md5sums... packer ... Skipped ==> Extracting sources... -> Creating working copy of packer git repo... Cloning into 'packer'... done. ==> Starting pkgver()... ==> Updated version: packer 20160325-1 ==> Entering fakeroot environment... ==> Starting package()... ==> Tidying install... -> Removing libtool files... -> Purging unwanted files... -> Removing static library files... -> Stripping unneeded symbols from binaries and libraries... -> Compressing man and info pages... ==> Checking for packaging issue... ==> Creating package "packer"... -> Generating .PKGINFO file... -> Generating .BUILDINFO file... -> Generating .MTREE file... -> Compressing package... ==> Leaving fakeroot environment. ==> Finished making: packer 20160325-1 (Tue May 10 18:39:42 IST 2016)
The above command will compile and create Packer installation file.
To view the newly installation file for packer, use the ls command:
Desktop packer PKGBUILD Downloads packer-20160325-1-any.pkg.tar.xz Soft_Backup Entertainment Personal src Pictures
As you in the above output, packer-20160325-1-any.pkg.tar.xz is the installation file.
Finally, install Packer using command:
$ sudo pacman -U packer-*.pkg.tar.xz
Optionally, install customizepkg package to apply customizepkg modifications.
$ sudo pacman -S customizepkg
That's it. Packer has been installed.
Now, you can start using Packer to install, update, upgrade packages as the way you do using Pacman. For other operations such as removing a package, use Pacman. Packer usage is same as Pacman. Refer the following guide to know how to use pacman. You can use the same guide for packer also.
For example, to install a package, run:
$ packer -S <package>
You can always use Packer as regular user. You need not to use sudo in front of every command. When packer needs administrative permissions, It will ask you to enter the root password.
That's all for now. I will be soon here with another interesting article. Until then, stay tuned with OSTechNix. If you find this article useful, please share it on your social, professional networks and support us.
Thanks for stopping by!
Help us to help you:
- Subscribe to our Email Newsletter : Sign Up Now
- Support OSTechNix : Donate Via PayPal
- Download free E-Books and Videos : OSTechNix on TradePub
- Connect with us: Facebook | Twitter | Google Plus | LinkedIn | RSS feeds
Have a Good day!!
I just check it. It works. Could you please elaborate the problem?
when I use this: wget https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=packer
I get this: zsh: no matches found: https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=packer
I don’t think it’s the URL problem. zsh shell might cause the problem. I don’t know how to fix this error at the moment. In BASH shell, it works perfectly as described in the guide.
Muchas gracias, excelente how to. Siempre que instalo archilinux vengo a esta guia para instalar packer. Funciona perfectamente.
de nada. Pero, se descontinúa ahora. Por favor use esto en su lugar. https://ostechnix.com/yay-found-yet-another-reliable-aur-helper/