LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Arch
User Name
Password
Arch This Forum is for the discussion of Arch Linux.

Notices


Reply
  Search this Thread
Old 02-16-2020, 02:20 PM   #1
JonBardo
LQ Newbie
 
Registered: Dec 2018
Posts: 13

Rep: Reputation: Disabled
Correct way to install an AUR package


Hello,

I'm not really sure what is the best way to install an AUR package. What I usually do is clone de git repo, then "makepkg -sic" and that is it.

I've also seen people doing "make clean install" instead, and other people doing "makepkg -s" then "pacman -u".
 
Old 02-16-2020, 02:27 PM   #2
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
I think it would be
"make install clean"
because running clean first would clean out the compiled binaries ending up empty with nothing to install. I have not ran arch, but its clones, and use yum or pacman.

Last edited by BW-userx; 02-16-2020 at 02:28 PM.
 
Old 02-17-2020, 04:06 AM   #3
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by JonBardo View Post
I've also seen people doing "make clean install"
That's not the same thing at all. It's a "manual" install that completely ignores distro package management.
Quote:
and other people doing "makepkg -s" then "pacman -u".
That’s basically the same as
Code:
makepkg -si
 
1 members found this post helpful.
Old 03-12-2020, 10:47 AM   #4
RickDeckard
Member
 
Registered: Jan 2014
Location: Canton, Georgia, USA
Distribution: Debian 12
Posts: 205

Rep: Reputation: Disabled
If your package has a shell script for installation, you can try there.
 
Old 12-02-2020, 09:27 AM   #5
MattMadness
LQ Newbie
 
Registered: Aug 2020
Location: New York
Distribution: Arch Linux
Posts: 19

Rep: Reputation: Disabled
You have a few methods of installation:

Best Way:
With an AUR Helper. These programs take care of the installation of packages from the AUR for you. I would recommend pikaur or yay. However you have to install these programs the manual way, which we'll get to here too.

Manual Way:
This involves "git clone"ing the source code from the AUR, and building from source. Here is how you install yay, for example...

Code:
$ sudo pacman -S git
$ git clone https://aur.archlinux.org/yay.git
$ cd yay
$ makepkg -si
Notice how we build with makepkg. It is the special program Arch has to automatically handle the build process of all AUR packages. There is generally no need to use the "make" command, because makepkg runs it anyways. The help of makepkg shows this:

Code:
matthew@Matthew-Netbook ~> makepkg --help
makepkg (pacman) 5.2.2

Make packages compatible for use with pacman

Usage: /usr/bin/makepkg [options]

Options:
  -A, --ignorearch Ignore incomplete arch field in PKGBUILD
  -c, --clean      Clean up work files after build
  -C, --cleanbuild Remove $srcdir/ dir before building the package
  -d, --nodeps     Skip all dependency checks
  -e, --noextract  Do not extract source files (use existing $srcdir/ dir)
  -f, --force      Overwrite existing package
  -g, --geninteg   Generate integrity checks for source files
  -h, --help       Show this help message and exit
  -i, --install    Install package after successful build
  -L, --log        Log package build process
  -m, --nocolor    Disable colorized output messages
  -o, --nobuild    Download and extract files only
  -p <file>        Use an alternate build script (instead of 'PKGBUILD')
  -r, --rmdeps     Remove installed dependencies after a successful build
  -R, --repackage  Repackage contents of the package without rebuilding
  -s, --syncdeps   Install missing dependencies with pacman
  -S, --source     Generate a source-only tarball without downloaded sources
  -V, --version    Show version information and exit
  --allsource      Generate a source-only tarball including downloaded sources
  --check          Run the check() function in the PKGBUILD
  --config <file>  Use an alternate config file (instead of '/etc/makepkg.conf')
  --holdver        Do not update VCS sources
  --key <key>      Specify a key to use for gpg signing instead of the default
  --noarchive      Do not create package archive
  --nocheck        Do not run the check() function in the PKGBUILD
  --noprepare      Do not run the prepare() function in the PKGBUILD
  --nosign         Do not create a signature for the package
  --packagelist    Only list package filepaths that would be produced
  --printsrcinfo   Print the generated SRCINFO and exit
  --sign           Sign the resulting package with gpg
  --skipchecksums  Do not verify checksums of the source files
  --skipinteg      Do not perform any verification checks on source files
  --skippgpcheck   Do not verify source files with PGP signatures
  --verifysource   Download source files (if needed) and perform integrity checks

These options can be passed to pacman:

  --asdeps         Install packages as non-explicitly installed
  --needed         Do not reinstall the targets that are already up to date
  --noconfirm      Do not ask for confirmation when resolving dependencies
  --noprogressbar  Do not show a progress bar when downloading files

If -p is not specified, makepkg will look for 'PKGBUILD'
Using this documentation, we can see that "s" will sync the dependencies of the packages, "i" will install the package. You could use the "c" flag to clean up the build after installation, but most people don't do that.

I would recommend using an AUR helper, so you don't have to go to the AUR website to check every time something might have an update (what a hassle!). I would recommend using the pikaur aur helper, I've gotten into it and like it more then yay.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] No package 'x11' found No package 'xext' found No package 'xdamage' found No package 'xfixes' found No package 'x11-xcb' found Jigsaw Linux From Scratch 14 02-23-2021 08:35 PM
AUR Package - Search for Updates llewellen Arch 3 07-01-2018 12:46 PM
libssl-dev, SDL, libX11: finding the corresponding package in AUR? 0li Arch 5 02-23-2016 12:07 PM
[SOLVED] unable to install package-query-1.5 from AUR 1asipper Linux - Newbie 2 01-31-2015 08:09 PM
LXer: Archlinux tools: AUR LXer Syndicated Linux News 0 11-08-2007 02:10 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Arch

All times are GMT -5. The time now is 09:26 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration