Skip to content

in-source new-building gtk2hs/gtk3 #3425

Closed
@lspitzner

Description

@lspitzner

added a cabal.project to the project, try to new-build

> git clone https://github.com/lspitzner/gtk2hs.git --depth=5 --branch=new-build
> cd gtk2hs
> cabal new-build gtk/
Resolving dependencies...
In order, the following will be built (use -v for more details):
cairo-0.13.1.1
glib-0.13.2.2
gio-0.13.1.1
pango-0.13.1.1
gtk3-0.14.2
ghc-pkg: cannot create: $PROJECT/dist-newstyle/packagedb/ghc-7.10.3 already exists

first problem. [this might appear somewhat non-deterministically. or i messed up my testing once.] fixed by just trying again:

> cabal new-build gtk/
[tons of successful compilation, until:]
$PROJECT/dist-newstyle/build/gtk3-0.14.2/setup/setup.hs:1:1:
    Could not find module ‘Prelude’
    It is a member of the hidden package ‘base-4.8.2.0’.
    Perhaps you need to add ‘base’ to the build-depends in your .cabal file.
    Use -v to see a list of the files searched for.

This seems to resemble #3320 (or #3394), but the cabal.project already adds +build-demos, i thought. well, next workaround: add custom-setup:

(new clone because i delete the entire directory anyways to prevent any residual state between builds.)

> git clone https://github.com/lspitzner/gtk2hs.git --depth=5 --branch=new-build-workaround
> cd gtk2hs
> cabal new-build gtk/
[tons of successful compilation, until:]
Linking $PROJECT/dist-newstyle/build/gtk3-0.14.2/setup/setup ...
[1 of 2] Compiling Gtk2HsSetup      ( Gtk2HsSetup.hs, dist/setup-wrapper/Gtk2HsSetup.o )
[2 of 2] Compiling Main             ( SetupMain.hs, dist/setup-wrapper/Main.o )
Linking dist/setup-wrapper/setup ...
unrecognized 'configure' option `--profiling-detail=default'

unrecognized 'configure' option `--library-profiling-detail=default'

unrecognized 'configure' option `--ipid=gtk3-0.14.2-inplace'

not sure how to continue.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions