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

horizon-eda-unstable: init at 2019-02-27 #56497

Open
wants to merge 3 commits into
base: master
from
Open

horizon-eda-unstable: init at 2019-02-27 #56497

wants to merge 3 commits into from

Conversation

@Luz
Copy link
Contributor

Luz commented Feb 28, 2019

Motivation for this change
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 nox --run "nox-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)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

sha256 = "0qxw3vsbf9cg6b3pp3z1k2fjl8xrnjdr2gcncnr5jzd1mix6yd4y";
};

# Version in specific format, created by: "git log -1 --pretty="format:%h %ci %s"

This comment has been minimized.

Copy link
@joachifm

joachifm Mar 23, 2019

Contributor

Updating this by hand seems like it'd get annoying after a while. What about just taking part of src.rev or does it have to have that format? Or at least use git within the build to produce the thing.

Also note that overriding patchPhase prevents users from passing additional patches via patches; not necessarily a problem, but something to be aware of.

echo "const char *gitversion = \"810fc8d 2019-02-27 00:05:27 +0100 fix some includes\";" > src/gitversion.cpp
'';

buildInputs = [ pkgconfig sqlite libyamlcpp libuuid gnome3.gtkmm epoxy librsvg zeromq cppzmq glm libgit2 curl boost python3 opencascade ];

This comment has been minimized.

Copy link
@joachifm

joachifm Mar 23, 2019

Contributor

I think pkgconfig makes more sense as a native build input

NIX_CFLAGS_COMPILE = "-I${opencascade}/include/oce";

installPhase = ''
mkdir -p $out/bin

This comment has been minimized.

Copy link
@joachifm

joachifm Mar 23, 2019

Contributor

Golfing: I believe this reduces to install -Dt $out/bin horizon-{eda,imp}

@joachifm

This comment has been minimized.

Copy link
Contributor

joachifm commented Mar 23, 2019

@GrahamcOfBorg build horizon-eda

@Luz Luz closed this Jul 16, 2019
@Luz Luz deleted the Luz:horizon-eda branch Jul 16, 2019
@Luz Luz restored the Luz:horizon-eda branch Jul 16, 2019
@Luz Luz reopened this Jul 16, 2019
Copy link
Contributor

aanderse left a comment

I have left a few comments I hope you will find helpful.

{ stdenv, fetchFromGitHub, pkgconfig, sqlite, libyamlcpp, libuuid, gnome3, epoxy, librsvg, zeromq, cppzmq, glm, libgit2, curl, boost, python3, opencascade, libzip, podofo, wrapGAppsHook }:

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

This comment has been minimized.

Copy link
@aanderse

aanderse Aug 5, 2019

Contributor

Please use pname = "horizon-eda"; instead as name = "${pname}-${version}"; is already implied.


stdenv.mkDerivation rec {
name = "horizon-eda-${version}";
version = "20190716";

This comment has been minimized.

Copy link
@aanderse

aanderse Aug 5, 2019

Contributor

If a package is not a release but a commit from a repository, then the version part of the name must be the date of that (fetched) commit. The date must be in "YYYY-MM-DD" format. Also append "unstable" to the name - e.g., "pkgname-unstable-2014-09-23".

echo "const char *gitversion = \"${src.rev}\";" > src/gitversion.cpp
'';

buildInputs = [ pkgconfig sqlite libyamlcpp libuuid gnome3.gtkmm epoxy librsvg zeromq cppzmq glm libgit2 curl boost python3 libzip podofo opencascade ];

This comment has been minimized.

Copy link
@aanderse

aanderse Aug 5, 2019

Contributor

Please see comment by @joachifm about pkgconfig belonging to nativeBuildInputs instead.


meta = with stdenv.lib; {
description = "A free EDA software to develop printed circuit boards";
homepage = https://github.com/carrotIndustries/horizon;

This comment has been minimized.

Copy link
@aanderse

aanderse Aug 5, 2019

Contributor

Please quote.

'';

preFixup = ''
wrapProgram "$out/bin/horizon-eda" "''${gappsWrapperArgs[@]}"

This comment has been minimized.

Copy link
@aanderse

aanderse Aug 5, 2019

Contributor

Is this actually required?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.