[Plib-users] OS X Solution
Brought to you by:
sjbaker
|
From: Mat D. <mdd...@en...> - 2002-11-09 19:45:10
|
So I've made some headway on the OSX problem.
In order to get everything working correctly, I made a Carbon
Framework, called plib, with all headers in it and compiled it with the
libs in /usr/lib. Then, I installed the framework in
/System/Library/Frameworks/ and included it into my project. I also
removed all the headers from /usr/include/plib so that there wouldn't
be any confusion. For some reason, OSX was treating those headers as C
headers and wasn't using C++. You might post this solution to the site
or something, it was a major hassle to get working.
m.
On Saturday, November 9, 2002, at 11:17 AM, Mat Davidson wrote:
> Ok, so I've got a mild answer to this problem. The only way Ive found
> to get it working is to:
>
> 1.) take the plib headers and move them from /usr/include/plib to the
> directory that is local the project
> 2.) move #include<plib/xx.h> to #include "xx.h"
>
> its strange and I still don't have a decent explanation for it. Got
> any ideas?
>
> mat.
>
>
> On Saturday, November 9, 2002, at 09:49 AM, Steve Baker wrote:
>
>> Mat Davidson wrote:
>>> the exact g++ errors are:
>>> Mkdir
>>> /Volumes/Storage/mat/Desktop/ttt3d-0.2.0/ttt3d/build/ttt3d.build/
>>> ttt3d.build/Objects-normal/ppc CompileCplusplus
>>> /Volumes/Storage/mat/Desktop/ttt3d-0.2.0/ttt3d/build/ttt3d.build/
>>> ttt3d.build/Objects-normal/ppc/cell.o In file included from
>>> /usr/include/plib/ssg.h:28,
>>> from /Volumes/Storage/mat/Desktop/ttt3d-0.2.0/src/p3d.h:36,
>>> from /Volumes/Storage/mat/Desktop/ttt3d-0.2.0/src/cell.cxx:25:
>>
>> ttt3d sounds like the program in plib/demos - is that correct?
>> (it contains a file called 'cell.cxx' and another called 'p3d.h'
>> so I think it must be).
>>
>> Have you changed the code at all from what's in the PLIB demos distro?
>>
>> The standard version doesn't include any 'extern "C"' stuff - so any
>> problem
>> like that would have to be a bug in the official OS-X headers...which
>> seems
>> unlikely.
>>
>>> These are the kinds of errors Im getting.
>>> It might be interesting to note that it says "declaration of C
>>> function".....but I still don't know how to fix it
>>
>> Neither do I.
>>
>> There should be an option in GCC to make it emit the results of
>> the pre-processing stage. This is after the '#include' and '#define'
>> processing has been done.
>>
>> I would look through that and see if there are any unmatched 'extern
>> "C"'
>> commands.
>>
>> I'd also try to compile a VERY simple source file containing something
>> that's allowed in C++ and not in C and check that it compiles - just
>> as
>> a way to be sure that you really are using the compiler with the C++
>> part enabled and not somehow telling it to be a 'pure' C compiler.
>>
>> eg:
>>
>> int main ()
>> {
>> int x = 0 ;
>>
>> x = 123 ;
>>
>> int y = 0 ; <--- Legal in C++ - should generate an error
>> in C
>>
>> y = 456 ;
>> }
>>
>>
>> ...if that produces an error then the problem is that you have some
>> funny
>> problem with the compiler not recognising this as a C++ program and
>> compiling
>> it as C instead.
>> ---------------------------- Steve Baker -------------------------
>> HomeEmail: <sjb...@ai...> WorkEmail: <sj...@li...>
>> HomePage : http://web2.airmail.net/sjbaker1
>> Projects : http://plib.sf.net http://tuxaqfh.sf.net
>> http://tuxkart.sf.net http://prettypoly.sf.net
>>
>>
>>
>> -------------------------------------------------------
>> This sf.net email is sponsored by:ThinkGeek
>> Welcome to geek heaven.
>> http://thinkgeek.com/sf
>> _______________________________________________
>> plib-users mailing list
>> pli...@li...
>> https://lists.sourceforge.net/lists/listinfo/plib-users
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> plib-users mailing list
> pli...@li...
> https://lists.sourceforge.net/lists/listinfo/plib-users
|