Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix sys/soundcard.h related build failure on FreeBSD
The FreeBSD build was broken because special typedefs like `u_long` and `u_char` weren't known when including `sys/soundcard.h` during compile. When we introduced some strict POSIX/C11 flags with commit fad6a3e, this seems to have disabled the __BSD_VISIBLE flag on FreeBSD which made these typedefs disappear (there is a `#if __BSD_VISIBLE` guard in `sys/types.h`). We don't know the reason for disabling `__BSD_VISIBLE` (perhaps it is along the line of "if you want POSIX, you don't get BSD enhancements") and we don't know if there are adverse side-effects to manually enabling `__BSD_VISIBLE`, but for now it works. If anybody has deeper understanding of this and a better way to fix this, please speak up :) This fixes issue #105. (n.b.: `sys/soundcard.h` contains two sound systems: AIO and OSS. The missing typedefs are only used for AIO while we only need OSS. So if that header file would have been split into two seperate files, we would not have run into this problem. The OSS part should work fine with the POSIX/C11 flags without setting `__BSD_VISIBLE`.)
- Loading branch information