Login | Register
My pages Projects Community openCollabNet

Discussions > dev > RE: Re: Compile errors on OpenBSD 4.8

fsvs
Discussion topic

Hide all messages in topic

All messages in topic

Re: Compile errors on OpenBSD 4.8

Author froh
Full name Frode Haugsgjerd
Date 2011-06-26 04:05:32 PDT
Message >
> Thank you for your time and effort!
>
> When I've fixed all that - may I ask you to run a test-checkout &
> compile, to  see whether it works?
>
>
> Regards,
>
> Phil
>

Off cource I will!
Thank you for you patience.

Frode
Attachments

Re: Compile errors on OpenBSD 4.8

Author pmarek
Full name P.Marek
Date 2011-06-26 00:06:51 PDT
Message On Saturday 25 June 2011 Frode Haugsgjerd wrote:
> That worked, and adding this to configure also worked:
> if [ `uname -s` = "OpenBSD" ]
> then
> # OSX 10.6 - thanks, Florian.
> EXTRALIBS="-liconv"
> have_fmemopen=no
> fi
Ok, I'll add that.

 
> I talked to a Mr. "NicM" on #openbsd@freenode, who identified a use of
> iconv_open outside #ifdef HAVE_LOCALES in helper.c
>
> Then i supected HAVE_LOCALES was not set, and commented out the ifdef
> around #include <iconv.h>
> Now fsvs compiles.
Hmmm, so the HAVE_LOCALES detection doesn't work - because of the compiler
error.
I'll add another test for that.


Thank you for your time and effort!

When I've fixed all that - may I ask you to run a test-checkout & compile, to
see whether it works?


Regards,

Phil

--
Versioning your /etc, /home or even your whole installation?
             Try fsvs (fsvs.tigris.org)!

Re: Compile errors on OpenBSD 4.8

Author froh
Full name Frode Haugsgjerd
Date 2011-06-25 13:41:37 PDT
Message Hi again Phil !

2011/6/25 Philipp Marek <philipp at marek dot priv dot at>

> Hello Frode!
>
>
> > Now gmake fails much later:
> ...
> > /home/froh/sw/src/fs​vs-1.2/src/fsvs.c:47​6: undefined reference to
> `fmemopen'
> Well, this should be seen during configure - HAVE_FMEMOPEN - and then just
> the
> debug-buffer options should be disabled during compilation.
>
> You could try --enable-release - this would remove all debug print calls
> (although the
> function would have to be removed by the linker). But that shouldn't be
> necessary!
>
>
That worked, and adding this to configure also worked:
if [ `uname -s` = "OpenBSD" ]
then
        # OSX 10.6 - thanks, Florian.
        EXTRALIBS="-liconv"
        have_fmemopen=no
fi


> > /home/froh/sw/src/fs​vs-1.2/src/helper.c:​1436: undefined reference to
> > `iconv_open'
> ...
> > From a quick web search it seems fmemopen is a glibc only
> >
> > I did some testing of openbsd's iconv, as suggested in this thread:
> >
> https://bitbucket.or​g/medoc/recoll/issue​/61/configure-on-ope​nbsd-fails-on-iconv
> ...
> > $ gcc iconvtest.c
> > iconvtest.c:8: error: conflicting types for 'libiconv_open'
> > /usr/local/include/iconv.h:73: error: previous declaration of
> > 'libiconv_open' was here
> Well, this is a compile error; with FSVS it's a linker problem.
>
>

> Perhaps this is an artifact of not running configure again after the
> update; please
> re-run "make clean", "configure", and "make".
>

Thanks, but I always do this when recompiling.

I talked to a Mr. "NicM" on #openbsd@freenode, who identified a use of
iconv_open outside #ifdef HAVE_LOCALES in helper.c

Then i supected HAVE_LOCALES was not set, and commented out the ifdef
around #include <iconv.h>
Now fsvs compiles.

--
Frode Haugsgjerd
Norway
Attachments

Re: Compile errors on OpenBSD 4.8

Author pmarek
Full name P.Marek
Date 2011-06-25 11:23:48 PDT
Message Hello Frode!


> Now gmake fails much later:
...
> /home/froh/sw/src/fs​vs-1.2/src/fsvs.c:47​6: undefined reference to `fmemopen'
Well, this should be seen during configure - HAVE_FMEMOPEN - and then just the
debug-buffer options should be disabled during compilation.

You could try --enable-release - this would remove all debug print calls (although the
function would have to be removed by the linker). But that shouldn't be necessary!


> /home/froh/sw/src/fs​vs-1.2/src/helper.c:​1436: undefined reference to
> `iconv_open'
...
> From a quick web search it seems fmemopen is a glibc only
>
> I did some testing of openbsd's iconv, as suggested in this thread:
> https://bitbucket.or​g/medoc/recoll/issue​/61/configure-on-ope​nbsd-fails-on-iconv
...
> $ gcc iconvtest.c
> iconvtest.c:8: error: conflicting types for 'libiconv_open'
> /usr/local/include/iconv.h:73: error: previous declaration of
> 'libiconv_open' was here
Well, this is a compile error; with FSVS it's a linker problem.

Perhaps this is an artifact of not running configure again after the update; please
re-run "make clean", "configure", and "make".


Regards,

Phil


--
Versioning your /etc, /home or even your whole installation?
             Try fsvs (fsvs.tigris.org)!

Re: Compile errors on OpenBSD 4.8

Author pmarek
Full name P.Marek
Date 2011-06-25 02:13:22 PDT
Message > est_ops.c: In function 'ops__read_special_entry':
> est_ops.c:1728: error: 'ENODATA' undeclared (first use in this function)
> This one should be fixed since r2406, Dez 2003
Oh, sorry, that should be 2009, of course.


--
Versioning your /etc, /home or even your whole installation?
             Try fsvs (fsvs.tigris.org)!

Re: Compile errors on OpenBSD 4.8

Author pmarek
Full name P.Marek
Date 2011-06-25 00:04:48 PDT
Message Hello Frode!

On Friday 24 June 2011 Frode Haugsgjerd wrote:
> Hi, so far I've posted via "Discussions" on the web page, I can't find a
> subscribe button there. After some digging, I found that a email to
> dev-subscribe at fsvs dot tigris dot org does the trick. Sorry for my ignorance. It's
> been a while since I used tools like mutt and mailman :)
No problem, glad that this is solved.
 

> My real problems are with ops__read_special_entry
> in est_ops.c
And what is the real problem?
    est_ops.c: In function 'ops__read_special_entry':
    est_ops.c:1728: error: 'ENODATA' undeclared (first use in this function)
This one should be fixed since r2406, Dez 2003 ... now we're at r2455, so I
wouldn't understand how this could affect you.

There's no ENODATA anymore in the FSVS sources ... Please double-check whether
the checkout is current!

 
> Btw, I use fsvs on debian and really would like to be able to use it on our
> OBSD firewalls. I tailored the example scripts to my use, and exchanged
> the automatic nightly commit to a reminder email. Something like "fsvs
> diff /etc |mutt -s "Have you forgotten to commit your changes?" user@host"
> This forces me to commit changes with a proper log entry, and really helps
> tracking changes.
Yes, that would be one of the use cases ...


Regards,

Phil

--
Versioning your /etc, /home or even your whole installation?
             Try fsvs (fsvs.tigris.org)!

RE: Re: Compile errors on OpenBSD 4.8

Author froh
Full name Frode Haugsgjerd
Date 2011-06-23 17:24:36 PDT
Message Hi, so far I've posted via "Discussions" on the web page, I can't find a subscribe button there. After some digging, I found that a email to dev-subscribe at fsvs dot tigris dot org does the trick. Sorry for my ignorance. It's been a while since I used tools like mutt and mailman :)

I found the page http://fsvs.tigris.o​rg/source/browse/fsv​s/ and assumed that trunk was the latest and greatest. But if you assume...

It seems like I distracted you with all my talk about trampolines. In svn trunk the -ftrampolines flag was missing. When I tried the 1.2 branch, the trampoline error was fixed.

My GCC version is as reported by "gcc -v" 4.2.1
This is the version that comes bundled with the OS.
I found an error in my first post, the latest system I've tested this on is OpenBSD 4.9

My real problems are with ops__read_special_entry
 in est_ops.c

Btw, I use fsvs on debian and really would like to be able to use it on our OBSD firewalls. I tailored the example scripts to my use, and exchanged the automatic nightly commit to a reminder email.
Something like "fsvs diff /etc |mutt -s "Have you forgotten to commit your changes?" user@host" This forces me to commit changes with a proper log entry, and really helps tracking changes.

-Frode

RE: Re: Compile errors on OpenBSD 4.8

Author pmarek
Full name P.Marek
Date 2011-06-23 00:49:09 PDT
Message Hello Frode!


First of all - how about subscribing, so that I don't have to moderate your emails?
If you like I can do that for you, too.


> Ok, forgot to mention that the version i compiled was trunk r. 2447
Uh, the trunk is defunct.


> Tried the 1.2 branch, same result, but except the trampoline error was gone.
I'm not sure what you mean - the trampoline error was gone on the 1.2 branch, or only
the trampoline error remained?


> Attached ./configure --enable-dev-fake 2>&1 |tee configure.log
> and make output
Are these when using the 1.2 branch?

What gcc version are you using? On the 48 page I see
   Gcc 2.95.3 (+ patches), 3.3.5 (+ patches) and 4.2.1 (+patches)

I cannot find anything about the "-ftrampoline" option ... Please add it in the
generated Makefile, and try compiling again.


Regards,

Phil


--
Versioning your /etc, /home or even your whole installation?
             Try fsvs (fsvs.tigris.org)!

RE: Re: Compile errors on OpenBSD 4.8

Author froh
Full name Frode Haugsgjerd
Date 2011-06-22 12:58:29 PDT
Message Ok, forgot to mention that the version i compiled was trunk r. 2447

Tried the 1.2 branch, same result, but except the trampoline error was gone.

Attached ./configure --enable-dev-fake 2>&1 |tee configure.log

and make output
Attachments

Re: Compile errors on OpenBSD 4.8

Author pmarek
Full name P.Marek
Date 2011-06-22 12:27:45 PDT
Message Hello Frode!

> Hi, I'm trying to compile fsvs on OpenBSD 4.8, and I have some problems.
> http://fsvs.tigris.org claims that this is reported to work, but all i can find is a
> thread from 2006 that don't answer my questions.
...
> Can anyone provide some pointers to what i should try next? I guess the error suggests
> that some dependency is not satisfied, but I am not fluent in C so I'm lost at this
> point.

Please try a svn checkout:

    http://fsvs.tigris.o​rg/svn/fsvs/branches​/fsvs-1.2.x/fsvs

because it has a few FreeBSD fixes that are not in a released tarball yet.

If we get OpenBSD 4.8 running, I'll cut a fresh release.


Regards,

Phil

--
Versioning your /etc, /home or even your whole installation?
             Try fsvs (fsvs.tigris.org)!

Compile errors on OpenBSD 4.8

Author froh
Full name Frode Haugsgjerd
Date 2011-06-22 10:36:34 PDT
Message Hi, I'm trying to compile fsvs on OpenBSD 4.8, and I have some problems. http://fsvs.tigris.org claims that this is reported to work, but all i can find is a thread from 2006 that don't answer my questions.

First some info about my setup.

OpenBSD 4.8
From obsd packages:
autoconf-2.60
GNU Make 3.81
pcre-8.02p1
apr-1.2.11p4
subversion-1.6.15p0
gdbm-1.8.3p0
rsync-3.0.7
gcc 4.2.1

To satisfy gcc i had to write #include <stdlib.h>
in /usr/include/alloca.h , as obsd dont have this header.

Then gcc complained about trampolines, and i added
CFLAGS += -ftrampolines
to src/Makefile.in

Now comilation fails on:
     CC est_ops.c
est_ops.c: In function 'ops__read_special_entry':
est_ops.c:1728: error: 'ENODATA' undeclared (first use in this function)
est_ops.c:1728: error: (Each undeclared identifier is reported only once
est_ops.c:1728: error: for each function it appears in.)
gmake[1]: *** [est_ops.o] Error 1
gmake: *** [default-target] Error 2

Can anyone provide some pointers to what i should try next? I guess the error suggests that some dependency is not satisfied, but I am not fluent in C so I'm lost at this point.

Best regards
Frode Haugsgjerd
Norway
Messages per page: