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

lxterminal: init at 0.3.1 #33240

Merged
merged 2 commits into from Jan 2, 2018
Merged

lxterminal: init at 0.3.1 #33240

merged 2 commits into from Jan 2, 2018

Conversation

velovix
Copy link
Contributor

@velovix velovix commented Dec 31, 2017

Motivation for this change

LXTerminal is the standard terminal emulator for LXDE, so LXDE users would expect it to exist. Subjectively, it's also a good desktop-agnostic terminal that I use even though I don't use LXDE.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-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 nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

@@ -359,6 +359,10 @@ with pkgs;

findXMLCatalogs = makeSetupHook { } ../build-support/setup-hooks/find-xml-catalogs.sh;

buildSingleXMLCatalog = makeSetupHook {
Copy link
Member

Choose a reason for hiding this comment

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

This now has a name parameter we should be using.

echo '</catalog>' >> catalog.xml
}

if [ -z "$buildSingleXMLCatalogHookDone" ]; then
Copy link
Member

Choose a reason for hiding this comment

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

You don't want this. Environment Hooks are functions applied to every dependency, but buildSingleXMLCatalog takes no argument. Just remove the whole if block and call the function manually (e.g. in preConfigure of the package you are packaging).

# Creates a single XML catalog that references the catalogs found by
# findXMLCatalogs.
# Useful for situations where only one catalog is expected.
buildSingleXMLCatalog() {
Copy link
Member

Choose a reason for hiding this comment

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

Probably better if this takes a single argument which is the output file produced.

Copy link
Member

@Ericson2314 Ericson2314 left a comment

Choose a reason for hiding this comment

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

Oops sorry that was supposed to be a "request changes" review.


configureFlags = [
"--enable-man"
"--with-xml-catalog=../catalog.xml" # Generated by buildSingleXMLCatalog
Copy link
Contributor

Choose a reason for hiding this comment

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

Alternately, it is possible to patch the m4 file to autodetect the catalog from the variable, see for example gnome3.cheese.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good to know, that makes things a lot easier.

Copy link
Contributor

Choose a reason for hiding this comment

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

The only issue is, the macro is in acinclude.m4 instead of the usual m4/gtkdoc_jh_check_xml_catalog.m4.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Right, and the m4 file has different contents as well. I ended up generating my own patch.

The patch removes the need for a separate script to combine existing
catalog files, making the package simpler.
@velovix
Copy link
Contributor Author

velovix commented Jan 2, 2018

Following the advice of @jtojnar I've removed the XML catalog combining setup hook in favor of a solution that patches the m4 file to respect the XML_CATALOG_FILES environment variable.

@Ericson2314: This sidesteps the problems you had found with the setup hook solution. Please take a look.

Copy link
Member

@Ericson2314 Ericson2314 left a comment

Choose a reason for hiding this comment

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

Yeah that was a great idea. Looks good!

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

5 participants