Following tutorial For pamac install base-devel git Got error

Was Reading this Thread
[HowTo] make a crash-proof backup for Manjaro - Contributions / Tutorials - Manjaro Linux Forum

witch Directed me here
https://wiki.manjaro.org/index.php/Arch_User_Repository#Accessing_the_AUR

pamac install base-devel git                                             
There are 24 members in group base-devel:
 1:  autoconf   2.69-7                 core
 2:  automake   1.16.2-3               core
 3:  binutils   2.35-2                 core
 4:  bison      3.6.4-1                core
 5:  fakeroot   1.24-2                 core
 6:  file       5.39-1                 core
 7:  findutils  4.7.0-2                core
 8:  flex       2.6.4-3                core
 9:  gawk       5.1.0-1                core
10:  gcc        10.2.0-2               core
11:  gettext    0.21-1                 core
12:  grep       3.4-1                  core
13:  groff      1.22.4-3               core
14:  gzip       1.10-3                 core
15:  libtool    2.4.6+42+gb88cebd5-14  core
16:  m4         1.4.18-3               core
17:  make       4.3-3                  core
18:  pacman     5.2.2-2                core
19:  patch      2.7.6-8                core
20:  pkgconf    1.7.3-1                core
21:  sed        4.8-1                  core
22:  sudo       1.9.3.p1-1             core
23:  texinfo    6.7-3                  core
24:  which      2.21-5                 core

Enter a selection (default=all): all

Enter a selection (default=all): 

Preparing...
Nothing to do.
Transaction successfully finished.
~ >>> git clone https://aur.archlinux.org/foo.git                              
fatal: destination path 'foo' already exists and is not an empty directory.
~ >>> cd foo                                                              [128]
~/foo >>> makepkg -s                                                  ±[master]
==> ERROR: foo is not available for the 'x86_64' architecture.
~/foo >>>                                                             ±[master]

Check that the “foo” package PKGBUILD has “x86_64” in it’s arch=() array.

PS: I can’t find a foo package in the AUR, so I assume you have replaced the real pkgname with foo in this example.

2 Likes

how ? Do I do that

thanks

Open the PKGBUILD file in a text editor.

pkgver=1.0.0
pkgrel=1
pkgdesc="Test package"
arch=('all')
licence=('GPL')

build() {
	cd .
}

package() {
	cd .
}

Change arch=('all') to arch=('any') and it should work.

2 Likes

ur the best

It Worked

~/foo >>> makepkg -s                                               ±[●][master]
==> Making package: foo 1.0.0-1 (Do 08 Okt 2020 20:00:51 CEST)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
==> Extracting sources...
==> Starting build()...
==> 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 issues...
==> Creating package "foo"...
  -> Generating .PKGINFO file...
  -> Generating .BUILDINFO file...
  -> Generating .MTREE file...
  -> Compressing package...
==> Leaving fakeroot environment.
==> Finished making: foo 1.0.0-1 (Do 08 Okt 2020 20:00:52 CEST)
~/foo >>> ls                                                      ±[●●][master]
foo-1.0.0-1-any.pkg.tar.xz  pkg  PKGBUILD  src
~/foo >>> sudo pacman -U foo.pkg.zst                              ±[●●][master]
[sudo] password for tempo: 
loading packages...
error: 'foo.pkg.zst': could not find or read package
~/foo >>> sudo pacman -U foo-1.0.0-1-any.pkg.tar.xz               ±[●●][master]
loading packages...
resolving dependencies...
looking for conflicting packages...

Packages (1) foo-1.0.0-1


:: Proceed with installation? [Y/n] y
(1/1) checking keys in keyring                     [######################] 100%
(1/1) checking package integrity                   [######################] 100%
(1/1) loading package files                        [######################] 100%
(1/1) checking for file conflicts                  [######################] 100%
(1/1) checking available disk space                [######################] 100%
:: Processing package changes...
(1/1) installing foo                               [######################] 100%
~/foo >>> ```

A Fast Question 

So I don't need to do these last 2 commands any more correct ?

makepkg -i  and   makepkg -is

A Fast Question

So I don’t need to do these last 2 commands any more correct ?

makepkg -i and makepkg -is

makepkg -si does what makepkg -i does, so you only need to do the -si one.
But no, you don’t need to do that, when you did pacman -U.

When you build the package again with makepkg, you can simply do makepkg -si and it will build and install the package and it’s dependencies. So you don’t need the pacman -U command.

2 Likes

You can also use pamac build command with no argument to build and install from the PKGBUILD in the current directory. It automatically check for base-devel packages and other dependencies needed.

1 Like

Can u please show me a command example for pacman build ?

Thank u

pamac build google-chrome
1 Like

@Chrysostomus

Thank u Sir