Hey
I am very new to Linux and G++/GCC. I acquired a Linux for PS2 kit recently and have been compiling under G++ fine (though coming from VC++ I had to research Makefiles and a few other things).
I tried to include a sound library that had been posted to the Linux4PS2 comunity forums. It is a single C and H duo. Here is my problem: if I compile it under GCC it won't link with the rest of my app which is all CPP (it complains for unreferenced functions) which I guess is due to name mangling. But that file alone will compile under GCC.
When I try to compile it under G++ it yells at me the following warning:
soundlib.c:464: implicit declaration of function 'int memalign(....)'
I searched the net and a found a suggestion to put #define __EXTENSIONS__ ahead of the stdlib.h include. I tried it and still no joy. I also tried substituting posix_memalign for memalign, but that gave the same error.
Any advice greatly appreciated.
Cheers
-A-
I am very new to Linux and G++/GCC. I acquired a Linux for PS2 kit recently and have been compiling under G++ fine (though coming from VC++ I had to research Makefiles and a few other things).
I tried to include a sound library that had been posted to the Linux4PS2 comunity forums. It is a single C and H duo. Here is my problem: if I compile it under GCC it won't link with the rest of my app which is all CPP (it complains for unreferenced functions) which I guess is due to name mangling. But that file alone will compile under GCC.
When I try to compile it under G++ it yells at me the following warning:
soundlib.c:464: implicit declaration of function 'int memalign(....)'
I searched the net and a found a suggestion to put #define __EXTENSIONS__ ahead of the stdlib.h include. I tried it and still no joy. I also tried substituting posix_memalign for memalign, but that gave the same error.
Any advice greatly appreciated.
Cheers
-A-