Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

darktable: move documentation to it's own directory #72160

Conversation

roosemberth
Copy link
Contributor

Motivation for this change

Package documentation in the wrong directory. Creates collisions when merging system paths.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
Notify maintainers

cc @

Signed-off-by: Roosembert Palacios <roosembert.palacios@epfl.ch>
Copy link
Contributor

@mrVanDalo mrVanDalo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No functional tests needed, because documentation is just moved around. And it builds, so all good I would say.

Copy link
Contributor

@mrVanDalo mrVanDalo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No functional tests needed, because documentation is just moved around. And it builds, so all good I would say.

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/prs-already-reviewed/2617/113

Copy link
Contributor

@jtojnar jtojnar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a bug in CMake setup hook. It should be fixed there instead.

The issue is that $shareDocName

cmakeFlags="-DCMAKE_INSTALL_DOCDIR=${!outputDoc}/share/doc/${shareDocName} $cmakeFlags"

is only defined when using multiple outputs:

if [ -z "$shareDocName" ]; then
local confScript="$configureScript"
if [ -z "$confScript" ] && [ -x ./configure ]; then
confScript=./configure
fi
if [ -f "$confScript" ]; then
local shareDocName="$(sed -n "s/^PACKAGE_TARNAME='\(.*\)'$/\1/p" < "$confScript")"
fi
# PACKAGE_TARNAME sometimes contains garbage.
if [ -n "$shareDocName" ] || echo "$shareDocName" | grep -q '[^a-zA-Z0-9_-]'; then
shareDocName="$(echo "$name" | sed 's/-[^a-zA-Z].*//')"
fi
fi

To fix that here, I suggest adding outputs = [ "out" "doc" ]; between pname and src.

Edit: Opened an issue about the underlying problem: #82304

@jtojnar
Copy link
Contributor

jtojnar commented Mar 11, 2020

It is more complicated than that, see #82304. For now you can set shareDocName manually.

alyssais added a commit to alyssais/nixpkgs that referenced this pull request Jun 24, 2020
This reverts commit 730133e.

multiple-outputs.sh has been fixed, so documentation is now
corrrrectly installed under $out/share/doc/darktable.

Fixes: NixOS#72160
Fixes: NixOS#83248
@jtojnar
Copy link
Contributor

jtojnar commented Jul 19, 2020

The change was actually reverted, #93166 is a proper fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants