[Dev] "systemd" placeholder for now?

Luke Shumaker lukeshu at lukeshu.com
Fri Jul 27 19:23:53 GMT 2018

On Fri, 27 Jul 2018 13:01:46 -0400,
Freemor wrote:
>  1.) I'm new the doing PKGBUILD so this is probably really rough and hackish
>  2.) I'm not experienced enough to be sure that it wouldn't cause instability
>      for people that are using systemd by jumping ahead and being the
>      default=1 choice during an install which would probably break all kinds
>      of things.

It only provides the prompt for "virtual" packages, which are packages
that no package actually has that name, and instead are *only* listed
in provides=() for packages with different names.  Because there's an
actual pkgname=systemd package, it wouldn't trigger the prompt for
"systemd" (but it might for "systemd-tools").

I've gone ahead made a few changes to the PKGBUILD and pushed this to
[pcr], but made you Maintainer.



    $ namcap PKGBUILD 
    PKGBUILD (systemdcompat) W: Missing Maintainer tag
    PKGBUILD (systemdcompat) E: Child package openrc-systemd-placeholder does not have a valid package() function                              
    PKGBUILD (openrc-systemd-placeholder) E: Missing url

namcap ("pacman", backwards) is a linter for PKGBUILD and package
files.  We've decided that it has too many false-positives to build in
to libremakepkg (it's commented out there), but it's a good idea to
run it on all of your PKGBUILDs until you have a good idea about the
things it complains about.

> # Maintainer (Parabola): Freemor <freemor at freemor.ca>

We only put " (Distro)" for things other than Parabola (otherwise
namcap complains).
> # A meta package to make packages that wrongly depends=('systemd')
> # When all they really wnat is udev happy in a non systemd system
> #
> # Designed for Parabola where notsystemd-common lives
> _spkgrel=1.parabola1
> #_repo=https://repo.parabola.nu/libre/os   #Not sure what this should be set to for this

`_repo` is a weird idiosyncrasy of Artix Linux packages; it only
appears in PKGBUILDs we imported from there.

Variables starting with `_` are "private" variables to that specific
PKGBUILD, makepkg and other tools make no use of them; there's no need
to set them if you don't use them.  (Exception: Autobuilder makes
special use of of `_commit` for packages that are built from software
that lives at git.parabola.nu).

> pkgbase=systemdcompat
> pkgname=('openrc-systemd-placeholder')

pkgbase is only necessary for split packages--for that mater, so are
the paraens on pkgname.  You should have just written


> pkgver=239
> pkgrel=2
> pkgrel+=.parabola1

There's no need to use more than a simple integer for a PKGBUILD that
isn't based on another PKGBUILD.

> arch=('any')
> license=('GPL2')
> groups=('base-openrc' 'openrc-base')
> pkgdesc="A meta package to provides systemd for packages that improperly depend on it; systemd compatibility package"
> provides=("systemd=${pkgver}")
> depends=("notsystemd-common")
> conflicts=('systemd' 'eudev-systemdcompat')
> replaces=('systemd-dummy')

Happy hacking,
~ Luke Shumaker

More information about the Dev mailing list