Skip to content

How to build Chart-cairo? #32

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

Closed
rvl opened this issue Jan 25, 2019 · 8 comments
Closed

How to build Chart-cairo? #32

rvl opened this issue Jan 25, 2019 · 8 comments

Comments

@rvl
Copy link
Contributor

rvl commented Jan 25, 2019

Chart-cairo is one of our dependencies.
It requires gtk2hs to build.

@angerman
Copy link
Collaborator

What exactly is the issue here? Does Chart-cairo list gtk2hs as a build-dependency?

@MarcFontaine
Copy link
Contributor

There is the following custom-setup section in cairo.cabal

custom-setup
  setup-depends: base >= 4.6,
                 Cabal >= 1.24 && < 2.5,
                 gtk2hs-buildtools >= 0.13.2.0 && < 0.14

When installing cairo I get the following error:

building '/nix/store/8sg61zwbw9mq7x50ii7sqp7gld3i6acc-cairo-0.13.6.0-setup.drv'...
unpacking sources
unpacking source archive /nix/store/42j0kj40xp0xkl3szl9i0a9n1blhkil8-cairo
source root is cairo
building
Compiling package Setup.hs
[1 of 1] Compiling Main             ( Setup.hs, Setup.o )

Setup.hs:5:1: error:
    Could not find module `Gtk2HsSetup'
    Use -v to see a list of the files searched for.
  |
5 | import Gtk2HsSetup ( gtk2hsUserHooks )
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
builder for '/nix/store/8sg61zwbw9mq7x50ii7sqp7gld3i6acc-cairo-0.13.6.0-setup.drv' failed with exit code 1

@MarcFontaine
Copy link
Contributor

The nix-tools generate a setup-depends = [.... section that looks good,
however when I changed it to setup-depends = [ some-gibberish] it turned out that the setup-depends section is actually ignored.

@luke-clifton
Copy link
Contributor

luke-clifton commented Jun 12, 2019

#124

@ocharles
Copy link
Contributor

ocharles commented Jul 1, 2019

Even with #124, I still can't get gtk2hs-buildtools to build:

building '/nix/store/7ziakcw3x2yi1y77yzkmlfi31j765zci-gtk2hs-buildtools-0.13.5.0-lib-gtk2hs-buildtools.drv'...
unpacking sources
unpacking source archive /nix/store/mdy5pih3qq31ac0zxpqq4s0gxncjcdka-gtk2hs-buildtools-0.13.5.0.tar.gz
source root is gtk2hs-buildtools-0.13.5.0
patching sources
configuring
Configure flags:
--prefix=/nix/store/v4jr1w9lbzpqlqsbv9khzs1baczy4zm3-gtk2hs-buildtools-0.13.5.0-lib-gtk2hs-buildtools lib:gtk2hs-buildtools --package-db=clear --package-db=/nix/store/1bv3v7xjbqrf91waibdasc1apphm6hj0-gtk2hs-buildtools-0.13.5.0-lib-gtk2hs-buildtools-config/package.conf.d --flags=closuresignals --with-ghc=ghc --with-ghc-pkg=ghc-pkg --with-hsc2hs=hsc2hs --with-gcc=cc --with-ld=ld --with-ar=ar --with-strip=strip --disable-executable-stripping --disable-library-stripping --disable-library-profiling --disable-executable-profiling --docdir=/nix/store/yh4cfxq0fgich1xx4lvpg17h7gdqmx2y-gtk2hs-buildtools-0.13.5.0-lib-gtk2hs-buildtools-doc/share/doc/gtk2hs-buildtools --enable-split-sections
Configuring library for gtk2hs-buildtools-0.13.5.0..
Warning: The flag --disable-executable-profiling is deprecated. Please use
--disable-profiling instead.
building
Preprocessing library for gtk2hs-buildtools-0.13.5.0..
alex: /nix/store/nk97zcz6ig8a5c6l43lkjl45f7avjf05-alex-3.2.4-exe-alex/share/x86_64-linux-ghc-8.6.4/alex-3.2.4-4z7ZKMgSjOO4NyQnKAtfMw-alex/AlexTemplate-ghc-nopred: openFile: does not exist (No such file or directory)
builder for '/nix/store/7ziakcw3x2yi1y77yzkmlfi31j765zci-gtk2hs-buildtools-0.13.5.0-lib-gtk2hs-buildtools.drv' failed with exit code 1

Not sure what this means yet...

@angerman
Copy link
Collaborator

angerman commented Jul 1, 2019

Could it be that

/nix/store/nk97zcz6ig8a5c6l43lkjl45f7avjf05-alex-3.2.4-exe-alex/share/x86_64-linux-ghc-8.6.4/alex-3.2.4-4z7ZKMgSjOO4NyQnKAtfMw-alex/AlexTemplate-ghc-nopred: openFile: does not exist (No such file or directory)

Is due to cabals mishandling of datadirs? haskell/cabal#5862

@ocharles
Copy link
Contributor

No, applying the patch https://patch-diff.githubusercontent.com/raw/haskell/cabal/pull/6055.diff to Cabal does not fix this problem.

@ocharles
Copy link
Contributor

I think this can now be closed as a duplicate of #31, but I think it's still a problem.

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

No branches or pull requests

5 participants