Just tryingg to compile media-sound/lmms +stk and compilation fails when merghing stk. In file included from RtAudio.cpp:6750:0: include/soundcard.h:106:28: fatal error: machine/endian.h: No such file or directory compilation terminated. make[1]: *** [RtAudio.o] Error 1 I'm googling to found out which dependency should be merged that install that file. Reproducible: Always Steps to Reproduce: 1.emerge -1 stk 2. 3. Actual Results: emake failed
I cannot upload the build log, every time I try it just fails to do so. Sorry for that.
Created attachment 327514 [details] build.log
Probleme located to building against OSS, it build fine with -oss USE flag. I'mm using OSS4 and oss-4.2.xxxx does not install anyy endian.h header file. Trying to locate the right header file(s).
I tried to found endian.h file to no avail. Although /usr/lib/oss/include/sys/soundcard.h installed by OSS4 contains the variable introduced by <machine/endian.h>. So now, it's not that simple patch to make because I have no idea what oss-3.xx install at all. I could try to patch that file to include the previous (oss) file and add an `-I/usr/lib/oss/include' but this will depend on OSS4 only?
Created attachment 331010 [details, diff] stk-4.4.4-RtAudio.cpp.patch I have solved the issue. The endian.h needed is provided by glibc - not by oss, so I patched the soundcard.h included with the stk sources to point to <endian.h> instead of <machine/endian.h>. After that, compilation failed with numerous errors such as "‘PCM_CAP_OUTPUT’ was not declared in this scope". After a little hunting, it turns out that these declarations are only made in the souncard.h which is provided by oss - not by the soundcard.h provided with the stk sources or the one provided by sys-kernel/linux-headers (the one provided by glibc just points to the linux-headers version). I provide all the above info in case anyone wants to know what the problem and fix was. In any case, I provide a patch for RtAudio.cpp to include the correct soundcard.h. In addition, the media-libs/stk ebuild should be updated to include DEPEND="oss? ( media-sound/oss )" so that the correct header file will be available during stk compilation.
Thanks Patrick! I was a few hints when I openned this bug that the symbols in question was provided by OSS package rather than glibc. I have a custom oss ebuild on my [bar-]overlay which make lin `/usr/include/oss' to `/usr/lib/oss/include' and add a `/usr/lib/pkgconfig/OSSlib.pc' which right point to the library and compilation FLAGS. So with your confirmed hints, I only have `<oss/sys/soundcard.h>' instead of a *hard link* to the file in question. Anyway, oss is broken since kernel 3.2 (?). I cannot make it work with 3.4 anymore and I don't have the time to look for a fix. Or rather, I don't want to spent hours on it.
As for OSS4, I was able to compile it with no trouble on my system running a 3.7.1 kernel. Perhaps it may no longer compile on older kernels, but unless you actually need an old kernel version, compilation should succeed. If it doesn't, open up a Gentoo bug. If I misunderstood and you're talking about OSS3 included in the kernel sources not compiling, that sounds like a bug for kernel.org.
can you retry with 4.5.1-r1?