Skip to content

Instantly share code, notes, and snippets.

@android10
Last active February 16, 2024 03:52
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save android10/9c906b5f281e5efcab4b561837c307fa to your computer and use it in GitHub Desktop.
Save android10/9c906b5f281e5efcab4b561837c307fa to your computer and use it in GitHub Desktop.
SCRIPT to install Pacaur on Arch Linux: https://wiki.archlinux.org/index.php/AUR_helpers
#ATTENTION: Check the Troubleshooting items below if you have problems, you can also visit my website where I wrote about it.
# LINK: https://fernandocejas.com/blog/engineering/2020-12-28-install-arch-linux-full-disk-encryption/#aur-helper
#!/bin/bash
#Make sure the system is up to date.
sudo pacman -Syu --noconfirm
#Install dependency packages we'll need to build Pacaur on Arch.
sudo pacman -S binutils make gcc fakeroot expac yajl git --noconfirm
#Create a temporary working directory for installing Pacaur.
mkdir -p ~/tmp/pacaur_install
cd ~/tmp/pacaur_install
#Install pacaur from AUR: Download the files from git and build a .tar.xz file then install it.
curl -o PKGBUILD https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=pacaur
makepkg -i PKGBUILD --noconfirm
sudo pacman -U pacaur*.tar.xz --noconfirm
#Now clean up system: deleting temporary directory.
rm -r ~/tmp/pacaur_install
cd -
@android10
Copy link
Author

android10 commented Mar 19, 2019

Troubleshooting 1

If you run into trouble with specific dependencies, install them first using pacman:

sudo pacman -S your_dependency

@android10
Copy link
Author

android10 commented Mar 19, 2019

Troubleshooting 2

I also bumped into another dependency issue related to auracle-git

You will have to build it from source and here are the steps:

1. Use wget to get the auracle-git.

wget https://aur.archlinux.org/cgit/aur.git/snapshot/auracle-git.tar.gz

2. Uncompress auracle-git:

tar -xzf auracle-git.tar.gz

2. Build the package:

cd auracle-git
makepkg PKGBUILD --skippgpcheck --noconfirm

3. Use pacman to build the already generated package:

pacman -U auracle-git-*

4. Re run install_pacaur.sh to install pacaur:

./install_pacaur.sh

@android10
Copy link
Author

android10 commented Apr 13, 2020

Troubleshooting 3

$VISUAL and $EDITOR environment variables not set or defined editor not found


1. Add to ~/.bashrc file the EDITOR variable :

export EDITOR="/usr/bin/vim" 

2. And then:

source ~/.bashrc

@StarleyRibeiro
Copy link

I am trying install the pacaur using your script and the following error is showed to me:

[starley@HP-EliteBook8460p ~]$ ./inst_pacaur.sh
Couldn't get a file descriptor referring to the console
warning: autoconf-2.69-7 is up to date -- skipping
warning: automake-1.16.2-1 is up to date -- skipping
warning: binutils-2.34-2 is up to date -- skipping
warning: bison-3.5.4-1 is up to date -- skipping
warning: fakeroot-1.24-2 is up to date -- skipping
warning: file-5.38-3 is up to date -- skipping
warning: findutils-4.7.0-2 is up to date -- skipping
warning: flex-2.6.4-3 is up to date -- skipping
warning: gawk-5.0.1-2 is up to date -- skipping
warning: gcc-9.3.0-1 is up to date -- skipping
warning: gettext-0.20.1-3 is up to date -- skipping
warning: grep-3.4-1 is up to date -- skipping
warning: groff-1.22.4-3 is up to date -- skipping
warning: gzip-1.10-3 is up to date -- skipping
warning: libtool-2.4.6+42+gb88cebd5-11 is up to date -- skipping
warning: m4-1.4.18-3 is up to date -- skipping
warning: make-4.3-3 is up to date -- skipping
warning: pacman-5.2.1-4 is up to date -- skipping
warning: patch-2.7.6-8 is up to date -- skipping
warning: pkgconf-1.6.3-3 is up to date -- skipping
warning: sed-4.8-1 is up to date -- skipping
warning: sudo-1.8.31.p1-1 is up to date -- skipping
warning: texinfo-6.7-2 is up to date -- skipping
warning: which-2.21-5 is up to date -- skipping
warning: git-2.26.1-1 is up to date -- skipping
there is nothing to do
gpg: key 1EB2638FF56C0C53: 47 signatures not checked due to missing keys
gpg: key 1EB2638FF56C0C53: "Dave Reisner d@falconindy.com" not changed
gpg: Total number processed: 1
gpg: unchanged: 1
Cloning into 'cower'...
remote: Enumerating objects: 4, done.
remote: Counting objects: 100% (4/4), done.
remote: Compressing objects: 100% (4/4), done.
remote: Total 4 (delta 0), reused 4 (delta 0), pack-reused 0
Unpacking objects: 100% (4/4), 1.06 KiB | 544.00 KiB/s, done.
==> Making package: cower 18-1 (Wed Apr 15 13:25:12 2020)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
-> Downloading cower-18.tar.gz...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
curl: (22) The requested URL returned error: 404
==> ERROR: Failure while downloading https://pkgbuild.com/~dreisner/sources/cower/cower-18.tar.gz
Aborting...
[starley@HP-EliteBook8460p ~]$

@Meg4R0M
Copy link

Meg4R0M commented Apr 16, 2020

hi !

Cower is no longer available. u need tu use another way =)

btw trizen > pacaur =)

@android10
Copy link
Author

android10 commented Apr 16, 2020

@StarleyRibeiro check the Threshold section right below the script. As @psykoterro pointed out cower is no longer available but in its replacemente you use Auracle.

Related to trizen I have not tried it yet but I'm happy with pacaur, especially because of the CLI commands are a replica from the built-in pacman.

Everything should work if you follow up the steps below. Let me know. @psykoterro thanks for the comment :).

@StarleyRibeiro
Copy link

@android10

Hi again,

I have installed cower package from following link: http://archlinuxgr.tiven.org/archlinux/x86_64/cower-18-2-x86_64.pkg.tar.xz.
I could notice the following library is missing in system: "libffi"
I have installed using pacman and just now, everything I try executing, the following error is displayed:

[starley@HP-EliteBook8460p ~]$ mousepad
mousepad: error while loading shared libraries: libffi.so.6: cannot open shared object file: No such file or directory

after doing a graceful reboot, I could notice the system is breaked (kernel panic).

Someone could help me out with this!?

@android10
Copy link
Author

@StarleyRibero I have the Troubleshooting 2 that explains step by step how to install auracle. Cower is not necessary anymore. That might have caused your issue.

I would remove what you installed with:

pacman -Rns "your_package"

Then do a fresh install as detailed here but without installing cower, you do not need it anymore.

@StarleyRibeiro
Copy link

StarleyRibeiro commented Apr 17, 2020

@android10

Hi again,

Tks a lot for your feedback. I followed the suggestion of psykoterro and installed the trizen. I had no troubles during instalation and apparently, everything is fine so far.

I just have one point of consideration of related to trizen, it's written in pear, and I preffer (that's my oppinion) package managers which are writter in bash, because that's the native language of shell, but I can survive with this.

I another situation will try again to install pacaur.

brgds,
Starley

@aiky967
Copy link

aiky967 commented Feb 13, 2022

I'm following your steps. I'm at makepkg PKGBUILD --skippgpcheck --noconfirm I got this error

Making package: auracle-git r366.8739929-4 (Sunday 13 February 2022 10:51:10 PM)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
-> Updating auracle git repo...
Fetching origin
-> Found 0001-Update-abseil-cpp-to-LTS-20211102.0-version.patch
-> Found 0002-Force-fmt-dependency-to-static.patch
==> WARNING: Skipping verification of source file PGP signatures.
==> Validating source files with b2sums...
auracle ... Skipped
0001-Update-abseil-cpp-to-LTS-20211102.0-version.patch ... Passed
0002-Force-fmt-dependency-to-static.patch ... Passed
==> Extracting sources...
-> Creating working copy of auracle git repo...
Reset branch 'makepkg'
==> Starting prepare()...
patching file meson.build
patching file subprojects/abseil-cpp.wrap
patching file meson.build
==> Starting pkgver()...
==> Removing existing $pkgdir/ directory...
==> Starting build()...
Directory does not contain a valid build tree:
/home/aiky/tmp/pacaur_install/auracle-git/src/auracle/build
==> ERROR: A failure occurred in build().
Aborting..

I installed all the dependencies as you said that were missing.

@android10
Copy link
Author

hey @aiky967 I would suggest to use yay or paru, pacaur has not been maintained for a while so I would suggest to the other alternatives.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment