Commit Graph

21 Commits

Author SHA1 Message Date
sternenseemann
8499ca252a mandoc: move executableCross assert into meta.broken
For splicing to work, callPackage needs to be able to attach extra
attributes (e. g. nativeDrv) to pkgsHostTarget.mandoc. If we have the
assert like before, pkgsHostTarget.mandoc would fail to evaluate,
preventing buildPackages.mandoc (which works as expected) to be attached
to the former. This affected cross compilation of the netbsd package set
in particular.
2022-01-23 15:18:45 +01:00
sternenseemann
3ab8db0ad0 mandoc: fix executableCross condition
isCompatible concerns itself with architecture compatibility which does
not constitute executability by itself, since there are other key
factors like the Kernel/syscall interface targeted. As mode switching is
considered compatible (e.g. ppc64le and ppc64), we can't even use
isCompatible to establish the architecture subset of executability.
For the lack of a better alternative, we'll just compare the system
tuples for now which will loose us support for x86_64-linux ->
i686-linux, but this is probably a bearable consequence.
2022-01-23 15:18:45 +01:00
sternenseemann
d110798747 nixos/tests/man: test common functionality of both man impls 2021-12-31 11:17:34 +01:00
sternenseemann
f16721775e mandoc: allow makewhatis(8) to index the nix store
To make makewhatis(8) index manual pages which are symlinks to the nix
store, we need to set READ_ALLOWED_PATH to include
`builtins.storeDir`. For background and discussion see:
https://inbox.vuxu.org/mandoc-tech/c9932669-e9d4-1454-8708-7c8e36967e8e@systemli.org/T/

This is a small change required as a prerequisite for #139333 which
causes a mass-rebuild for darwin, so it has to go through staging.
Since the change is trivial and has basically no chance of breaking
anything, we'll let it go through staging on its own, the modules
can be reviewed and merged into master later.
2021-11-15 17:18:36 +01:00
sternenseemann
03480209d9 mandoc: set SBINDIR instead of relying on fixupPhase 2021-09-23 21:24:10 +02:00
sternenseemann
c138683757 mandoc: use symlinks for executables and man pages
Symlinks are quite heavily used in nixpkgs and easier to reason about
than hardlinks, so using them seems good for consistency.
2021-09-23 21:24:10 +02:00
sternenseemann
ad02b5c89e mandoc: set MANPATH_BASE additionally to MANPATH_DEFAULT
MANPATH_BASE is used by mandoc -T lint to check if man pages that are
referenced exist on the system. While this feature is a bit problematic
for us (e. g. it will never work correctly in the nix sandbox), it
hasn't even worked in an impure context before since MANPATH_BASE
defaults to /usr/share/man:/usr/X11R6/man.
2021-09-23 21:24:10 +02:00
sternenseemann
a43f48b710 mandoc: support cross as far as possible
mandoc can't be cross compiled easily since all configure checks rely on
executing a binary built using $CC. We can however still do “native”
cross compilation like pkgsStatic and pkgsLLVM. To facilitate this, the
following changes are required:

* Set the correct AR to use in configure.local

* Inform users that cross compilation will fail via a throw if the build
  platform can't execute the host platform's binaries.
2021-09-23 21:24:10 +02:00
sternenseemann
35e8d91d92 mandoc: fix UTF-8-support detection and make more robust at runtime
locale(1) is not available in pkgsMusl.stdenv, but it is also not really
necessary. We just need to tell mandoc about *any* UTF-8 locale that is
also available at runtime.

For macOS C.UTF-8 is not available sadly, so we need to use
en_US.UTF-8. Using locale(1) for this is out of the question as NetBSD's
locale(1) depends on mandoc.
2021-09-23 21:24:10 +02:00
sternenseemann
342cabea95 mandoc: run regression test suite 2021-09-23 21:24:10 +02:00
sternenseemann
a0a2b5f788 mandoc: use printf instead of echo for writing configure.local
This should be a bit more robust and portable.
2021-09-23 20:55:22 +02:00
sternenseemann
71fae710cc mandoc: add myself as maintainer 2021-09-23 20:55:22 +02:00
sternenseemann
02abcd6b3b mandoc: 1.14.5 -> 1.14.6 2021-09-23 20:55:20 +02:00
Profpatsch
4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00
Michael Reilly
84cf00f980
treewide: Per RFC45, remove all unquoted URLs 2020-04-10 17:54:53 +01:00
volth
46420bbaa3 treewide: name -> pname (easy cases) (#66585)
treewide replacement of

stdenv.mkDerivation rec {
  name = "*-${version}";
  version = "*";

to pname
2019-08-15 13:41:18 +01:00
R. RyanTM
adcd13060f
mandoc: 1.14.4 -> 1.14.5
Semi-automatic update generated by
https://github.com/ryantm/nixpkgs-update tools. This update was made
based on information from
https://repology.org/metapackage/mandoc/versions
2019-04-07 12:47:59 +02:00
Jörg Thalheim
df4696cf2d mandoc: fix cc detection 2018-08-27 08:21:43 +01:00
Brayden Banks
a28dc898a5 mandoc: 1.13.4 -> 1.14.4 2018-08-26 18:12:59 -07:00
Silvan Mosberger
f5fa5fa4d6 pkgs: refactor needless quoting of homepage meta attribute (#27809)
* pkgs: refactor needless quoting of homepage meta attribute

A lot of packages are needlessly quoting the homepage meta attribute
(about 1400, 22%), this commit refactors all of those instances.

* pkgs: Fixing some links that were wrongfully unquoted in the previous
commit

* Fixed some instances
2017-08-01 22:03:30 +02:00
Ram Kromberg
c528892280 mandoc: init at 1.13.4 2016-09-15 20:44:43 +03:00