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

Fix build for cabal users that don't have systemd #1775

Merged
merged 1 commit into from
Oct 2, 2020

Conversation

hasufell
Copy link
Contributor

This is mainly due to a cabal bug and should be removed in
the future: haskell/cabal#5444

There are various distros, where installing development files
of libsystemd won't be an option:

  • Alpine (doesn't have systemd at all)
  • Gentoo (not installable when eudev is installed)
  • Exherbo (not installable when eudev is installed)

Users are expected to run the script and then execute cabal like so:

cabal build --project-file=cabal.nosystemd.project all


related:

This has also been discussed on slack.

Instructions for this edge case should probably be added to the wiki?

@CodiePP
Copy link
Contributor

CodiePP commented Aug 27, 2020

very good point! we should add documentation for this case also in https://github.com/input-output-hk/iohk-monitoring-framework

@hasufell
Copy link
Contributor Author

ping

@ghost
Copy link

ghost commented Sep 29, 2020

I have also having the same issue on Debian 10, tried the mentioned 2 fixes in the previous thread none of them works.

cabal build all -f-systemd
Warning: Requested index-state2020-07-15T00:00:00Z is newer than
'hackage.haskell.org'! Falling back to older state (2020-07-14T22:50:55Z).
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: lobemo-scribe-systemd-0.1.0.0 (user goal)
[__1] next goal: libsystemd-journal (dependency of lobemo-scribe-systemd)
[__1] rejecting: libsystemd-journal-1.4.4 (conflict: pkg-config package
libsystemd==209 || >209, not found in the pkg-config database)
[__1] rejecting: libsystemd-journal-1.4.3, libsystemd-journal-1.4.2,
libsystemd-journal-1.4.1, libsystemd-journal-1.4.0, libsystemd-journal-1.3.4,
libsystemd-journal-1.3.3, libsystemd-journal-1.3.1, libsystemd-journal-1.3.0,
libsystemd-journal-1.2.0, libsystemd-journal-1.1.0, libsystemd-journal-1.0.0
(constraint from project config TODO requires >=1.4.4)
[__1] fail (backjumping, conflict set: libsystemd-journal,
lobemo-scribe-systemd)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: libsystemd-journal,
lobemo-scribe-systemd

@hasufell
Copy link
Contributor Author

@feraldruid22 download the file in this PR: https://github.com/input-output-hk/cardano-node/pull/1775/files#diff-5739590c0f8579b6c8fac793aac34e6c

run it. Then invoke cabal as such: cabal build --project-file=cabal.nosystemd.project all

@mark-stopka
Copy link
Contributor

@hasufell
Copy link
Contributor Author

hasufell commented Oct 1, 2020

Is anyone going to review this?

@mark-stopka
Copy link
Contributor

mark-stopka commented Oct 1, 2020 via email

Copy link
Contributor

@intricate intricate 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 fine to me, but I'd also like a review from @erikd since he suggested this solution in #1666 (review).

This is mainly due to a cabal bug and should be removed in
the future: haskell/cabal#5444

There are various distros, where installing development files
of libsystemd won't be an option:

- Alpine (doesn't have systemd at all)
- Gentoo (not installable when eudev is installed)
- Exherbo (not installable when eudev is installed)

Users are expected to run the script and then execute cabal like so:

  cabal build --project-file=cabal.nosystemd.project all
@hasufell
Copy link
Contributor Author

hasufell commented Oct 2, 2020

bors merge

@iohk-bors
Copy link
Contributor

iohk-bors bot commented Oct 2, 2020

🔒 Permission denied

Existing reviewers: click here to make hasufell a reviewer

@intricate
Copy link
Contributor

bors r+

@iohk-bors
Copy link
Contributor

iohk-bors bot commented Oct 2, 2020

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

Successfully merging this pull request may close these issues.

None yet

5 participants