3

I am wishing to install mdm display manager in ArchLinux. Normally the similar gdm is used, but I want to be consistent with the Cinnamon desktop I use, instead of Gnome desktop, so I'd also like to use mdm instead of gdm.

Unfortunately, pacman does not see mdm, nor mdm-display-manager, etc... All searches with pacman -Ss for similar keywords proves to be unsucessful.

The packages are available for manual download here, but I do not know what to do with this .tar.gzfile. pacman do not let me install it with the -U option - basically it says it is not a package.

If I unzip it and try to use makepkg, then it appears to do some work, but eventually I get an error from systemctl saying that mdm.service doesn't exist.

How am I supposed to install packages which aren't automatically available through pacman?

Bregalad
  • 995
  • 3
  • 10
  • 14
  • Is your [AUR mdm package](https://aur.archlinux.org/packages/mdm-display-manager/) built correctly or not? It has several dependencies that must be fulfilled, the linked page provides the dependency list. There are some AUR packages in the dependency list but they do appear in the PKGBUILD file, therefore they're optional dependencies. – grochmal Jul 20 '16 at 19:26
  • Well I'd like to know. I'll reboot in archlinux and print an exact log of what happens. – Bregalad Jul 20 '16 at 19:41
  • No, I mean if it *builds* correctly not install correctly. AUR packages are built with `makepkg` but installed with `pacman -U`. It is a two phase process. – grochmal Jul 20 '16 at 19:52
  • Oh I suddently got it to work. I assumed it was either makepkg or pacman, not both. I didn't know the package was sources, for some reason I assumed it to be binaries. So yeah, it compiled and now I got it working. Thanks. – Bregalad Jul 20 '16 at 20:23

1 Answers1

1

OK, so to not leave the question in unanswered state. As we concluded in the comments:


AUR packages are installed in 2 phases

This is intended by arch developers since anyone can submit an AUR package. When you download an AUR packages you should always check the PKGBUILD files for malicious code. Although AUR packages are verified by Trusted Users there are just too many of them. Moreover, I use arch for years and never saw malicious code in the installation script of any AUR package I use, nut some people argue that they have.

When you build your package with makeprg you need to fulfill all dependencies for the build to succeed. Several AUR packages contain source files that are compiled, some download the sources during the build process, others even download binary blobs (e.g. graphic card drivers). Therefore dependencies are often header files and libraries that must be there when the build runs.

makeprg produces a file <package>-<version>-<architecture>.pkg.tar.xz which then needs to be fed to pacman -U to be installed. This is also intended since then you do not need root permissions to run makepkg.

If you have sudo installed you can use makepkg -i to install the package once the build is complete. This is safe, since only pacman will be called with root permissions.

mdm

The procedure above specifically for the mdm-display-manager would look as follows:

$ wget https://aur.archlinux.org/cgit/aur.git/snapshot/mdm-display-manager.tar.gz
$ tar xzf mdm-display-manager.tar.gz
$ cd mdm-display-manager
$ makepkg

This will result in a file called mdm-display-manager-2.0.10-1-x86_64.pkg.tar.xz (or i686 if you're on that architecture), which you need to feed to pacman as root:

# pacman -U /path/to/package/mdm-display-manager-2.0.10-1-x86_64.pkg.tar.xz
grochmal
  • 8,489
  • 4
  • 30
  • 60
  • Not only you don't need root permissions, but you actually are required to not be root. Which I find pretty dumb myself, but it's just a matter of taste. Also I don't see how you could detect malicious code just by glaring at it, the chances that anyone would actually be able to do that are close to 0%, so if there's malicious code you're going to install it, root or not. – Bregalad Jul 22 '16 at 20:30