Re: FreeBSD Install

Mirko Viviani <[email protected]>
Newsgroups gmane.comp.cms.opengroupware.discuss.general
Message-ID <[email protected]>
Helge Hess wrote:

>> It's better but not enough because with this release the libobjc 
>> shipped with gcc 3.2.2 has thread enabled and to compile objc sources 
>> you have to add -pthread to the command line.
> 
> No, you just need to follow the instructions and use the libobjc 
> provided by OGo. Threading is not necessary for OGo and only slows down 
> the runtime.

I remember problems using 2.95 libobjc with gcc3... but I'll try.
Actually I libFoundation fails to compile with it, same problems with 
objc_* defines in config.h, I'll look further tomorrow.

> BTW: the real problem is that FreeBSD seems to come with a static 
> libobjc instead of a dynamic one and therefore, obviously ;-), the 
> dynamic link resolution is broken (libobjc itself should bring in 
> libpthread).

This is true, but if you want thread support in FreeBSD you have to link 
against libc_r instead of libc. There is not a separate libpthread or 
similar.

>> The switch --with-gnustep does not work and sincerely I haven't know why!
> 
> After the patch the GNUstep root is properly scanned for libobjc.

Ah, ok.

> [js]
> 
>> Rename it FreeBSD.mk and apply this patch to config.mk, it should work 
>> with other fbsd versions.
> 
> Hm. That will break if we update to new SpiderMonkey versions. Can you 
> submit the patch to Mozilla as well ? I'll do in our CVS.

Hem, I'm not familiar to submitting pathes to Mozilla, so if you have 
time feel free to do it. I'll look at it but starting from this saturday 
I'm in vacation! :-)

> I renamed FreeBSD.mk to FreeBSD_All.mk like with Linux.
> 
> Could you try whether my HEAD js works ?

Yes, it works.

>>>> [gnustep-db]
>>>> 1. Change the path of includes and lib
>>>
>>> Could you be more specific ?
>>
>> The FBSD postgres 7.3.3 port puts the includes in /usr/local/include 
>> instead in the subdir pgsql/ as before, so I modified the files like 
>> this:
> 
> 
> OK, let's just add /usr/local/include and /usr/local/include/pgsql to 
> the standard include path. Will do no harm to other environments.
> 
> Can you try what I checked in?

You have forgot to change the inclusion path, here the patch:

Index: EOAttribute+PostgreSQL72.h
===================================================================
RCS file: 
/cvs/OpenGroupware.org/ThirdParty/gnustep-db/PostgreSQL72/EOAttribute+PostgreSQL72.h,v
retrieving revision 1.1.1.1
diff -c -r1.1.1.1 EOAttribute+PostgreSQL72.h
*** EOAttribute+PostgreSQL72.h  9 Jul 2003 22:57:43 -0000       1.1.1.1
--- EOAttribute+PostgreSQL72.h  21 Jul 2003 17:35:05 -0000
***************
*** 28,34 ****
   #define ___PostgreSQL72_EOAttribute_H___

   #import <GDLAccess/EOAttribute.h>
! #include <pgsql/libpq-fe.h>

   @class NSString;

--- 28,34 ----
   #define ___PostgreSQL72_EOAttribute_H___

   #import <GDLAccess/EOAttribute.h>
! #include <libpq-fe.h>

   @class NSString;

Index: EOAttribute+PostgreSQL72.m
===================================================================
RCS file: 
/cvs/OpenGroupware.org/ThirdParty/gnustep-db/PostgreSQL72/EOAttribute+PostgreSQL72.m,v
retrieving revision 1.1.1.1
diff -c -r1.1.1.1 EOAttribute+PostgreSQL72.m
*** EOAttribute+PostgreSQL72.m  9 Jul 2003 22:57:43 -0000       1.1.1.1
--- EOAttribute+PostgreSQL72.m  21 Jul 2003 17:35:05 -0000
***************
*** 32,38 ****
   #else
   #include <postgres_types.h>
   #endif
! #include <pgsql/sql3types.h>

   // Sybase dateformat: (need to be corrected for PostgreSQL)
   static NSString *PGSQL_DATETIME_FORMAT  = @"%b %d %Y %I:%M:%S:000%p";
--- 32,38 ----
   #else
   #include <postgres_types.h>
   #endif
! #include <sql3types.h>

   // Sybase dateformat: (need to be corrected for PostgreSQL)
   static NSString *PGSQL_DATETIME_FORMAT  = @"%b %d %Y %I:%M:%S:000%p";
Index: PostgreSQL72Channel.h
===================================================================
RCS file: 
/cvs/OpenGroupware.org/ThirdParty/gnustep-db/PostgreSQL72/PostgreSQL72Channel.h,v
retrieving revision 1.1.1.1
diff -c -r1.1.1.1 PostgreSQL72Channel.h
*** PostgreSQL72Channel.h       9 Jul 2003 22:57:43 -0000       1.1.1.1
--- PostgreSQL72Channel.h       21 Jul 2003 17:35:05 -0000
***************
*** 28,34 ****
   #define ___PostgreSQL72_Channel_H___

   #import <GDLAccess/EOAdaptorChannel.h>
! #include <pgsql/libpq-fe.h>

   @class NSArray, NSString, NSMutableDictionary;

--- 28,34 ----
   #define ___PostgreSQL72_Channel_H___

   #import <GDLAccess/EOAdaptorChannel.h>
! #include <libpq-fe.h>

   @class NSArray, NSString, NSMutableDictionary;

>> The PGSQL var used in GNUmakefile is not defined and here should be 
>> /usr/local
> 
> 
> Yup. It's used when building SKYRiX RPMs and needs to stay for now, 
> doesn't hurt on other systems.

Ok, now is ok. Thx.

Ciao,
Mirko
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.