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 error: SpawnPrograms.c: fatal error: wait.h: No such file or directory #1

Open
barracuda156 opened this issue Dec 16, 2023 · 5 comments

Comments

@barracuda156
Copy link

/opt/local/bin/gcc-mp-12 -L/opt/local/libexec/openssl3/lib -L/opt/local/lib -Wl,-headerpad_max_install_names -arch ppc  -pipe -I/opt/local/libexec/openssl3/include -Os -arch ppc  -fPIC -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DSTDC_HEADERS=1 -DHAVE_INITGROUPS=1 -DHAVE_POLL=1 -DHAVE_MLOCK=1 -DHAVE_MLOCKALL=1 -DHAVE_MUNLOCKALL=1 -DHAVE_MADVISE=1 -DHAVE_MOUNT=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_LIBC=1 -DHAVE_XATTR=1 -DHAVE_LIBZ=1 -DHAVE_LIBCRYPTO=1 -DHAVE_LIBSSL=1 -DHAVE_EVP_MD_CTX_NEW=1 -DHAVE_EVP_MD_CTX_FREE=1 -DHAVE_EVP_BF_CBC=1 -DHAVE_EVP_RC2_CBC=1 -DHAVE_EVP_RC4=1 -DHAVE_EVP_DES_CBC=1 -DHAVE_EVP_DESX_CBC=1 -DHAVE_EVP_CAST5_CBC=1 -DHAVE_EVP_IDEA_CBC=1 -DHAVE_EVP_AES_128_CBC=1 -DHAVE_EVP_AES_256_CBC=1 -DHAVE_X509_CHECK_HOST=1 -DHAVE_DECL_OPENSSL_ADD_ALL_ALGORITHMS=1 -DHAVE_OPENSSL_ADD_ALL_ALGORITHMS=1 -DHAVE_DECL_SSL_SET_TLSEXT_HOST_NAME=1 -DHAVE_SSL_SET_TLSEXT_HOST_NAME=1 -DVERSION=\"5.3\" -c SpawnPrograms.c
SpawnPrograms.c:11:10: fatal error: wait.h: No such file or directory
   11 | #include <wait.h>
      |          ^~~~~~~~
compilation terminated.
make[1]: *** [SpawnPrograms.o] Error 1
@ColumPaget
Copy link
Owner

Hi barracuda,

This is an odd issue. 'wait.h' is a standard header that's part of libc, and should be in /usr/include. Could it be that you have to have to install libc-dev or something like that?

@barracuda156
Copy link
Author

It should be sys/wait.h: fekberg/GoHttp#6
(I can confirm it is there on my macOS too.)

@ColumPaget
Copy link
Owner

unfortunately on ubuntu I'm finding it's not in '/usr/include/sys', but in '/usr/include' instead. I guess I'll need do do something with autoconf to find it...

@barracuda156
Copy link
Author

It can be done via include macros too, something like:

#ifdef __APPLE__
#include <sys/wait.h>
#else
#include <wait.h>
#endif

@ColumPaget
Copy link
Owner

hmm, sys/wait.h compiles even though it's not in /usr/include/sys. It must be in one of the gcc include directories. This does mean I'll have to update everything that comes with a bundled libUseful!

thanks for reporting this. Does fileferry build if you make the change yourself?

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

2 participants