grpc-haskell icon indicating copy to clipboard operation
grpc-haskell copied to clipboard

c2hs fails on MacOS

Open kolmodin opened this issue 8 years ago • 0 comments

c2hs fails with errors like this;

Building grpc-0.1.0.0...
Preprocessing library grpc-0.1.0.0...
c2hs: C header contains errors:

/usr/include/time.h:153: (column 72) [ERROR]  >>> Syntax error !
  The symbol `__attribute__' does not fit here.

It's due to that c2hs fails to parse the C headers. We need something like this in the .cabal file, or add a new header file;

+  cpp-options:
+    -D__attribute__(x)=
+    -Drestrict=
+    -D__qos_class=
+    -D__relative_priority=
+    -D_Nullable=
+    -D_Nonnull=

kolmodin avatar Jan 18 '17 08:01 kolmodin