Additional ARM Packages

Ran pacman -Rcns, removed ~/.config/Code and ~/.vscode, then did as you said above before re-running makepkg -srci.

I’m guessing pacman -Rcns leaves behind a sym-link from before because I got this when I initially re-ran makepkg -srci on the old code:

:: Processing package changes...
(1/1) installing code                                                                                                       [###########################################################################] 100%
ln: failed to create symbolic link '/usr/bin/code': File exists
error: command failed to execute correctly

Tried repeating the procedure, but got the same error. Otherwise, the programme appears to still install and run correctly.

The weird thing is that I’ve looked in /usr/bin/ before and after installing the package and there is no symlink or file called code in there.

EDIT: Ignore that last bit. I misread the terminal output. Didn’t realise I was looking at one of the subdirectories of /usr/bin. Will manually remove the symlinks and repeat the install-uninstall process.

Probably because it was installed by the last package. Did you uninstall it first? I have seen that when the link is obsolete. I can see if I can put a rm in the .install file and see if it will do anything. The last package was linking to a different file and I changed it to what the .deb had in their post install.

Yup… just checked. Uninstalled the package then removed the symlink. Then reinstalled and uninstalled the package again. The symlink gets left behind after uninstalling.

@Strit

When opening a few scripts to test code I noticed that julia and julia-docs weren’t available in the Arch/Manjaro ARM repos (although they are in the x86_64 repos). This is possibly a bit niche, but I thought I might put it out there and see whether there’s any interest in these. I just tried the build instructions present on the julia GitHub repo and was able to build a working version of julia:

git clone git://github.com/JuliaLang/julia.git
cd julia
git checkout v1.5.0
make

Takes about an hour or so to build on the Pinebook Pro if you don’t set the -j flag.

Scatha% ./julia 
               _
   _       _ _(_)_     |  Documentation: https://docs.julialang.org
  (_)     | (_) (_)    |
   _ _   _| |_  __ _   |  Type "?" for help, "]?" for Pkg help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 1.5.0 (2020-08-01)
 _/ |\__'_|_|_|\__'_|  |  
|__/                   |

julia> Sys.ARCH
:aarch64

julia> Sys.CPU_NAME
"cortex-a53"

julia> Sys.MACHINE
"aarch64-unknown-linux-gnu"

Binary releases are also available at the Julia website Download page.

I’m currently trying to modify the PKGBUILD from the Arch x86_64 package to see if that will also build, as they have some cblas optimisations and such.

EDIT: There’s a julia-aarch64-git AUR package that seems to have done a better job than I could ever do. However, I get a build failure when trying to install it via yay.

I add to the code.install to uninstall the code bin link when uninstalling the package. Seems to work:

pre_remove() {
rm -f /usr/bin/code
}

Thanks a ton for your help I could have not done it with out you. I know nothing about coding.

This package has been pushed to the unstable branch when the mirrors sync.

code 1.50-1

@Darksky Instructions for switching branch are available in the WIKI.

No worries. Glad to have helped.

1 Like

Hi.

Is there a chance to add micro to Manjaro ? I think I remember it was available for some time but in the moment it is not.
I think it is a very useful and user friendly terminal editor for those who just got used to CTRL-X/C/V/S/…

It can be build from AUR but you always have to install the whole go dev environment.
There is a aarch64 binary on the github page.

I pushed today an upgraded code package with some bug fixes to the unstable branch when the mirrors sync:

code 1.50.1-1

Fixes:

https://github.com/microsoft/vscode/issues?q=is%3Aissue+milestone%3A%22September+2020+Recovery%22+is%3Aclosed+

Will give it a go later. Although I hadn’t noticed any bugs in the previous build.

And there is a binary package too : AUR (en) - micro-bin which is compatible with aarch64 architecture.

1 Like

Oh, great find. That is new and it works. The package maintainer has a lightly concerning view about alternative architectures in AUR, but on the bright side he did modify the package, so Hurray :smile:
A great editor for everyone who looks for an alternative to nano.

Seems fine. No issues found.

Something I use quite often is cryptmount, for mounting encrypted filesystems. I’m not sure why this isn’t in the core repos for Arch/Manjaro, as it is for Debian/Ubuntu. There is an AUR package, but this wouldn’t install on aarch64 architecture. Today, I finally got fed up and had a go at trying to fix it. Managed to get it to build. Tested it and it works on my existing encrypted filesystems. The problem was that the script the package contained wasn’t able to automatically detect aarch64 architecture, so I had to manually set it as a configure parameter. Would it be possible to add this package to the Manjaro ARM repos?

https://aur.archlinux.org/packages/cryptmount-arm/

1 Like

Have you tried just adding aarch64 to the arch=() array before building it?
I can’t see anything in its PKGBUILD that would keep it from building on aarch64.

PS: Just tested this, and you are right. It can’t guess arm architectures. Autotools suck at this. :frowning:

Yup. I could probably improve the PKGBUILD generally by adding a simple $CARCH detection code chunk, similar to the one present in the code-git AUR PKGUILD. Might be best to entirely sidestep the package’s means to auto-detect hardware.

Something like this:

# Maintainer: Benjamin Feakins <feakster at poster dot eu>
# Contributor: Mike Sampson <mike at sambodata dot com>
# Contributor: Andrea Benazzo <andy at qitty dot net>
# Modified PKGBUILD from https://aur.archlinux.org/packages/cryptmount/

pkgname=cryptmount-arm
pkgver=5.3.2
_pkgver=5.3
pkgrel=1
pkgdesc="Utility which allows an ordinary user to mount an encrypted file system"
arch=('i686' 'x86_64' 'arm' 'armv6h' 'armv7h' 'aarch64')
url="http://cryptmount.sourceforge.net/"
license=('GPL')
provides=(cryptmount)
depends=(cryptsetup device-mapper glibc libgcrypt systemd util-linux)
makedepends=(gcc)
source=($provides-$pkgver.tar.gz::http://downloads.sourceforge.net/project/cryptmount/cryptmount/cryptmount-$_pkgver/cryptmount-$pkgver.tar.gz)
backup=('etc/cryptmount/cmtab')
sha512sums=('972c7fefadb86bb82cdeb96b185f45bec08ac07d39474a4c7e2a473bc2453624ffcc387b6836a02260dcd0d1176a5a743c45bdf3d7e78d2f519f02a48c62a6b8')

prepare() {
  cd "$srcdir/$provides-$pkgver"

  case "$CARCH" in
    "x86_64")
      _arch=x86_64-unknown-linux-gnu
      ;;
    "arm")
      _arch=arm-unknown-linux-gnu
      ;;
    "armv6h")
      _arch=arm-unknown-linux-gnu
      ;;
    "armv7h")
      _arch=arm-unknown-linux-gnu
      ;;
    "aarch64")
      _arch=arm-unknown-linux-gnu
      ;;
    *)
      _arch=$(./config.guess)
      ;;
  esac
  echo "Build: $_arch"
}

build() {
  cd "$srcdir/$provides-$pkgver"

  ./configure --build=$_arch --prefix=/usr --sbindir=/usr/bin --sysconfdir=/etc --with-systemd=yes
  make
}

package() {
  cd "$srcdir/$provides-$pkgver"

  make DESTDIR="$pkgdir" install
}

Might drop a message to the current maintainer.

I got it to compile I am going to put together a PKGBUILD with a patch for you to test as I know nothing about testing it.

1 Like

Cool. Many thanks. What needed patching?

PS: Loving that directory structure ;p

Hold on I will give you a diff in the config.guess and you can save me the trouble putting it all together.

Make a patch and add it to the PKGBUILD with this in it:

diff -ruP a/config.guess b/config.guess
--- a/config.guess	2020-11-07 08:33:43.350091075 -0600
+++ b/config.guess	2020-11-07 08:31:51.377540483 -0600
@@ -156,6 +156,7 @@
 	case "${UNAME_MACHINE_ARCH}" in
 	    armeb) machine=armeb-unknown ;;
 	    arm*) machine=arm-unknown ;;
+       aarch64) machine=arm-unknown ;;
 	    sh3el) machine=shl-unknown ;;
 	    sh3eb) machine=sh-unknown ;;
 	    *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
@@ -163,7 +164,7 @@
 	# The Operating System including object format, if it has switched
 	# to ELF recently, or will in the future.
 	case "${UNAME_MACHINE_ARCH}" in
-	    arm*|i386|m68k|ns32k|sh3*|sparc|vax)
+	    arm*|aarch64|i386|m68k|ns32k|sh3*|sparc|vax)
 		eval $set_cc_for_build
 		if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
 			| grep __ELF__ >/dev/null
@@ -827,6 +828,9 @@
     arm*:Linux:*:*)
 	echo ${UNAME_MACHINE}-unknown-linux-gnu
 	exit 0 ;;
+    aarch64:Linux:*:*)
+        echo ${UNAME_MACHINE}-unknown-linux-gnu
+        exit 0 ;;
     cris:Linux:*:*)
 	echo cris-axis-linux-gnu
 	exit 0 ;;