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

Build: C: Implicit declaration of function strnlen #433

Open
foxyseta opened this issue Sep 18, 2024 · 0 comments
Open

Build: C: Implicit declaration of function strnlen #433

foxyseta opened this issue Sep 18, 2024 · 0 comments

Comments

@foxyseta
Copy link

I am having trouble building the latest version (5.0.18.4) via cabal.

[28 of 28] Compiling Hoogle           ( src/Hoogle.hs, dist/build/Hoogle.o, dist/build/Hoogle.dyn_o )

In file included from cbits/text_search.c:2:0: error:
/usr/include/fortify/string.h: In function 'strncat':

/usr/include/fortify/string.h:297:36: error:
     error: implicit declaration of function 'strnlen'; did you mean 'strlen'? [-Wimplicit-function-declaration]
      297 |                 __fh_size_t __sl = strnlen(__s, __n);
          |                                    ^~~~~~~
          |                                    strlen
    |
297 |                 __fh_size_t __sl = strnlen(__s, __n);
    |                                    ^
`gcc' failed in phase `C Compiler'. (Exit code: 1)
Error: cabal: Failed to build hoogle-5.0.18.4 (which is required by exe:hoogle
from hoogle-5.0.18.4). See the build log above for details.

I am on MUSL (Alpine Linux 3.20).

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