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

Bad header file: Cannot find a definition for grpc_server_add_insecure_http2_port and grpc_insecure_channel_create in the header file. #156

Open
FabianVegaA opened this issue Oct 21, 2023 · 0 comments

Comments

@FabianVegaA
Copy link

I have tried to install grpc-haskell using NixOS, with the next command:

nix-shell \
  -p cabal-install \
  -p haskell.compiler.ghc90 \
  -p zlib \
  -p grpc \
  --run "cabal install --minimize-conflict-set"

but I get

...
Failed to build grpc-haskell-core-0.1.0.
Build log (
/home/fabian/.cache/cabal/logs/ghc-9.0.2/grpc-haskell-core-0.1.0-0dac2d8993a1e282a5e9409b216420f37cedc942cda2c0e88d7d24087f3963a1.log
):
Configuring library for grpc-haskell-core-0.1.0..
Preprocessing library for grpc-haskell-core-0.1.0..
c2hs: Errors during expansion of binding hooks:

src/Network/GRPC/Unsafe.chs:262: (column 7) [ERROR]  >>> Unknown identifier!
  Cannot find a definition for `grpc_server_add_insecure_http2_port' in the header file.
src/Network/GRPC/Unsafe.chs:198: (column 7) [ERROR]  >>> Unknown identifier!
  Cannot find a definition for `grpc_insecure_channel_create' in the header file.

Error: cabal: Failed to build grpc-haskell-core-0.1.0 (which is required by
exe:myProject from myProject-0.0.0.0). See the build log above for
details.

With this cabal file

cabal-version:      3.0
name:               myProject
version:            0.0.0.0
license:            BSD-3-Clause
license-file:       LICENSE
author:             Fabián
maintainer:         na
category:           Codec
build-type:         Simple
extra-doc-files:    CHANGELOG.md

common warnings
    ghc-options: -Wall

executable interpreter
    import:           warnings
    main-is:          Main.hs
    other-modules:    Schema
    default-language: Haskell2010
    hs-source-dirs:   app
    build-depends:
        base
      , proto3-wire
      , grpc-haskell ^>=0.1.0

I'm using NixOS 23.05 in x86_64

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

1 participant