Skip to content

Build fails on MacOS: new release needed? #137

Description

@purcell

Hi! I naïvely tried to use opencv 0.0.2.1 in a Stack project on MacOS, and while compilation looked to be going well, it failed with the following error:

    [55 of 71] Compiling OpenCV.ImgProc.MiscImgTransform ( src/OpenCV/ImgProc/MiscImgTransform.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/OpenCV/ImgProc/MiscImgTransform.o )
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    [56 of 71] Compiling OpenCV.ImgProc.ImgFiltering ( .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/OpenCV/ImgProc/ImgFiltering.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/OpenCV/ImgProc/ImgFiltering.o )
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    [57 of 71] Compiling OpenCV.ImgProc.GeometricImgTransform ( .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/OpenCV/ImgProc/GeometricImgTransform.hs, .stack-work/dist/x86_64-osx/Cabal-2.2.0.1/build/OpenCV/ImgProc/GeometricImgTransform.o )
    clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument]
    
    /private/var/folders/hc/w17tmcyn47j16fs8h4rb3_6w0000gn/T/ghc8956_0/ghc_654.cpp:140:15: error:
         error: expected expression
                    , {}
                      ^
        |
    140 |             , {}
        |               ^
    1 error generated.
    `gcc' failed in phase `C Compiler'. (Exit code: 1)

This was on MacOS 10.14.2, with OpenCV 3.4.3_2 from homebrew, stack resolver lts-12.24, and extra-deps as follows:

extra-deps:
  - opencv-0.0.2.1
  - inline-c-cpp-0.2.1.0

It looks like this was perhaps the issue reported in #121 and fixed in #122, and indeed by depending on the git version of opencv it looks like I've got things working, but perhaps you'd consider pushing a new release so that's not necessary?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions