octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: compiling development sources on mac


From: Rob Mahurin
Subject: Re: compiling development sources on mac
Date: Fri, 18 Dec 2009 12:16:27 -0500
User-agent: Mutt/1.5.20 (2009-06-14)

On Thu, Dec 17, 2009 at 06:47:21PM -0500, Ben Abbott wrote:
> On Dec 16, 2009, at 6:11 PM, Rob Mahurin wrote:
> > I'm trying to build the octave development sources on OS X 10.5.8,
> > using dependencies installed via MacPorts.  I haven't tried to build
> > development sources since before gnulib/libtool was added to the process.
> > Currently I can get stuck in one of two places.
> > 
> > (1) trouble with libgnu/string.h
> > 
> > My refresh-and-compile command is
> > 
> >     hg pull && 
> >     hg update && 
> >     LIBTOOLIZE=glibtoolize ./autogen.sh &&  
> >     ./configure CC=gcc-mp-4.3 CXX=g++-mp-4.3 F77=gfortran-mp-4.3 
> > LDFLAGS=-L/opt/local/lib && 
> >     nice make -j4 
> > 
> > The compile fails with
> > 
> >     libtool: compile:  g++-mp-4.3 -DHAVE_CONFIG_H -I. -I.. 
> > -I/opt/local/include -I../libgnu -I../libcruft/misc -I../liboctave 
> > -I../liboctave -I. -I. -I/opt/local/include -g -O2 -DHAVE_CONFIG_H 
> > -mieee-fp -I/opt/local/include/freetype2 -I/opt/local/include 
> > -I/opt/local/include -Wall -W -Wshadow -Wold-style-cast -Wformat -g -O2 
> > -D_THREAD_SAFE -g -O2 -MT liboctinterp_la-lex.lo -MD -MP -MF 
> > .deps/liboctinterp_la-lex.Tpo -c lex.cc  -fno-common -DPIC -o 
> > .libs/liboctinterp_la-lex.o
> > In file included from lex.cc:20:
> >     ../libgnu/string.h:135: error: expected ',' or '...' before '__dest'
> >     ../libgnu/string.h:137: error: nonnull argument with out-of-range 
> > operand number (argument 1, operand 2)
> >     lex.cc:281: warning: use of old-style cast
> >     [many more warnings about old-style casts]
> >     make[3]: *** [liboctinterp_la-lex.lo] Error 1
> >     make[2]: *** [all] Error 2
> >     make[1]: *** [all-recursive] Error 1
> >     make: *** [all] Error 2
> 
> Rob,
> 
> I came across the thread below.
> 
>       
> http://old.nabble.com/string.h:82:-error:-expected-`,'-or-`...'-before-"__dest"-tt17579480.html#a17579907
> 
> Which prompted me to add the line below at the top of md5.c ... My
> error was different from yours. My build failed at md5.c, not with
> lex.cc
> 
>       #include <config.h>
> 
> I needed to add this line to the top of ...
> 
>       liboctave/md5.c
>       src/gl2ps.c
> 
> With those two changes, my build completed without error. However it
> doesn't run due to dylib conflicts which, I understand, are specific
> to my configuration.

Thanks.  Today I have to modify those files as well.

If I insert an include statement at the top of lex.cc, the
compile continues.  However, lex.cc is not part of the developer
sources:

        $ rm src/lex.cc && make -C src lex.cc
        /bin/sh ../build-aux/ylwrap lex.ll lex.octave_.c lex.cc -- flex -I -I

The generated lex.cc includes <config.h> about twelve hundred lines
in, where the contents of lex.ll appear.  But <string.h> is included
in the generated output up near the top of the file.  Is there a
"right" way to include <config.h> near the top of lex.cc, since that's
apparently a gnulib requirement?

> p.s. as this discussion related to the developers sources, I've
> moved it to the maintainers mail list.

Thanks.  In my original message I described a second failure in
builtins.cc.  My build now stops there.  Should I re-post details to
this list?

Thanks,
Rob


reply via email to

[Prev in Thread] Current Thread [Next in Thread]