Skip to content

Exception in thread "main" eta.runtime.exception.EtaException: WrapPCRE.hsc was not compiled against pcre library with HAVE_PCRE_H defined #978

Open

Description

@Boreaso

I want to use duckling on jvm and I built duckling-0.1.6.1 with --enable-uberjar-mode and run the excutable jar, it raised exception Exception in thread "main" eta.runtime.exception.EtaException: WrapPCRE.hsc was not compiled against pcre library with HAVE_PCRE_H defined, How can I solve it?
I am very eager to solve this problem.

Description

See above.

Expected Behavior

Build a single runnable jar without exception.

Actual Behavior

Raise a exception when run: Exception in thread "main" eta.runtime.exception.EtaException: WrapPCRE.hsc was not compiled against pcre library with HAVE_PCRE_H defined

Possible Fix

Steps to Reproduce

etlas build --enable-uberjar-mode

Context

Unable to use duckling in my project.

Your Environment

  • latest eta
  • latest etlas
  • duckling-0.1.6.1
  • ubuntu-18.04

Activity

  1. jneira commented on Oct 16, 2019

    @jneira
    Collaborator

    Maybe it is using a version of regex-pcre-builtin that is not patched to work with eta. The patched version is regex-pcre-builtin-0.94.4.8.8.35
    You can try to make the build use that version of the library adding a cabal.project like:

    packages: .
    
    constraints: bifunctors == 5.5.3,
                 regex-pcre-builtin == 0.94.4.8.8.35
    

    or alternatively run etlas build --constraint="bifunctors==5.5.3" --constraint="regex-pcre-builtin == 0.94.4.8.8.35"

    I've just tested that the library can be built with those constraints, downloading it with etlas update && etlas get duckling-0.1.6.1

  2. Boreaso commented on Oct 16, 2019

    @Boreaso
    Author

    Maybe it is using a version of regex-pcre-builtin that is not patched to work with eta. The patched version is regex-pcre-builtin-0.94.4.8.8.35
    You can try to make the build use that version of the library adding a cabal.project like:

    packages: .
    
    constraints: bifunctors == 5.5.3,
                 regex-pcre-builtin == 0.94.4.8.8.35
    

    or alternatively run etlas build --constraint="bifunctors==5.5.3" --constraint="regex-pcre-builtin == 0.94.4.8.8.35"

    I've just tested that the library can be built with those constraints, downloading it with etlas update && etlas get duckling-0.1.6.1

    Thank you for your answer. I can build it successfully, but I can't run the tests. When I excute etlas run duckling-test, it raise the exception described above.

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