Csound Csound-dev Csound-tekno Search About

Re: [Cs-dev] More on OSX

Date2005-05-02 18:46
FromVictor Lazzarini
SubjectRe: [Cs-dev] More on OSX
I have not touched cs.c, so yes, I'd say you have to do the
dirent fix there, as it hadn't been done. Wrap it with
ifdef DIRENT_FIX  please.

>
> With commenting out the non ANSI __attribute and using
> useDirentFix=1 I can build up to the error......
>
> gcc -DCSOUND_WITH_API -g -gstabs -O2 -DMACOSX -Wall
> -DPIPES -DDIRENT_FIX -DHAVE_FCNTL_H -DHAVE_UNISTD_H
> -DHAVE_STDINT_H -DHAVE_SYS_IOCTL_H -
DHAVE_SYS_TIME_H
> -DHAVE_SYS_TYPES_H -DHAVE_CTYPE_H -
DHAVE_TERMIOS_H
> -DHAVE_STRING_H -DHAVE_DIRENT_H -DBETA -I. -IH -c -o
> util1/csd_util/cs.o util1/csd_util/cs.c
> util1/csd_util/cs.c:122: undefined type, found `DIR'
> cpp-precomp: warning: errors during smart preprocessing,
> retrying in basic mode util1/csd_util/cs.c: In function
> `create_file_list': util1/csd_util/cs.c:122: `DIR'
> undeclared (first use in this function)
> util1/csd_util/cs.c:122: (Each undeclared identifier is
> reported only once util1/csd_util/cs.c:122: for each
> function it appears in.) util1/csd_util/cs.c:122: `d'
> undeclared (first use in this function)
> util1/csd_util/cs.c:126: warning: implicit declaration of
> function `opendir' util1/csd_util/cs.c:133: warning:
> implicit declaration of function `readdir'
> util1/csd_util/cs.c:133: warning: assignment makes pointer
> from integer without a cast util1/csd_util/cs.c:150:
> warning: implicit declaration of function `closedir'
> scons: *** [util1/csd_util/cs.o] Error 1 scons: building
> terminated because of errors.
>
> I assume this code has not been subjected to the DIR
> changes? Fixing that I am now at the error
>

You know, this might be scons, because here, just by
specifying pluginEnvironment.sharedLibrary(...), gcc
gets called with -dynamiclib.

With  pluginEnvironment.Append(LINKFLAGS = ['-dynamiclib'])
 I get two -dynamiclib options in the resulting
command-line. I removed it because of that, didn't think
it would affect your build; restoring won't affect my
build anyway. My fault, sorry; please keep the -framework
options because without them the linking gets messed up

> gcc -framework CoreMidi -framework CoreFoundation
> -framework CoreAudio -shared -o libbabo.dylib
> Opcodes/babo.os -L. -L. -L/usr/local/lib -L. -L. -lsndfile
> gcc: unrecognized option `-shared' ld: Undefined symbols:
> _main
> scons: *** [libbabo.dylib] Error 1
>
> The option shared has never been recognised by this
> compiler, but it user to make .dylib files.  We seem to
> have lost the line second line below?
>
> if getPlatform() == 'darwin':
>     pluginEnvironment.Append(LINKFLAGS = ['-dynamiclib'])
>     pluginEnvironment['SHLIBSUFFIX'] = '.dylib'
>
> With that restored I can build again.  Is this another
> OS10,2 v OS10.3 difference?

I don't think it's 10.2 - 10.3 difference, as I am on 10.2
here
myself. Perhaps it's a scons difference? I have the newer
gcc (3.3) developer tools though (you can get them from
Apple).

You can commit the changes alright; they should not have
any impact on the rest of us. Just
wrap the dirent fix with ifdef DIRENT_FIX
and I don't see it failing here.

Victor

> So I better not commit these changes until others have
> checked it out.
>
> ==John ffitch
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: NEC IT Guy Games.
> Get your fingers limbered up and give it your best shot. 4
> great events, 4 opportunities to win big! Highest score
> wins.NEC IT Guy Games. Play to win an NEC 61 plasma
> display. Visit http://www.necitguy.com/?r=20
> _______________________________________________
> Csound-devel mailing list
> Csound-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/csound-devel


-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.
Get your fingers limbered up and give it your best shot. 4 great events, 4
opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20
_______________________________________________
Csound-devel mailing list
Csound-devel@lists.sourceforge.net