There are few reasons why I stick to older OSes. In case of FreeBSD its my customized Imunes platform for network simulations... Anyway, back to root problem: gcc -std=gnu99 -DHAVE_CONFIG_H -DCONFDIR=\"/etc\" -DLOCALSTATEDIR=\"/var\" -DFORTIFY_SOURCE=2 -g -O2 -MT tincd.o -MD -MP -MF $depbase.Tpo -c -o tincd.o tincd.c &&\ mv -f $depbase.Tpo $depbase.Po tincd.c:52:20: getopt.h: No such file or directory tincd.c:102: error: elements of array `long_options' have incomplete type Im not very familiar with all those newer fancy build systems (deps tracking), but for some reason getopt.h is not picked up from src directory at all --- tincd.c.orig Fri Apr 8 11:48:11 2016 +++ tincd.c Fri Apr 8 11:48:29 2016 @@ -49,7 +49,7 @@ #include <time.h> #endif -#include <getopt.h> +#include "getopt.h" #include "pidfile.h" #include "conf.h" Of course this change cannot be implemented, because it will break all other systems. If this can be easly fixed, then please do it. If not, no problem... as this is trival to fix it by hand (for now...) Kind regards, Borg ---------- Original message ---------- From: Guus Sliepen <guus at tinc-vpn.org> To: tinc-devel at tinc-vpn.org Subject: Re: Commit 68f4ca7 issues Date: Fri, 8 Apr 2016 13:26:57 +0200 Message-ID: <20160408112657.GF3784 at sliepen.org> On Fri, Apr 08, 2016 at 12:29:27PM +0200, borg at uu3.net wrote:> I have issues building tincd-1.0.26 on FreeBSD 4.11While I do like to make things backwards compatible, tinc 1.0.26 is from 2015, and FreeBSD 4.11 is from 2005. Is there a reason you're sticking to 4.11, and/or do you have the same issue with a newer version of FreeBSD, like 10.3?> Seems commit 68f4ca711593416d0defd81199b176ba604c6cb1 > that "modernizes" build system was a bad idea after all? > Not sure why merging lib/ to src/ was done.It was done because in reality, there is no library, it was just an arbitrary split of source files into two directories. Putting it all into one removed this split and made things like link-time optimization possible.> Most software I see contains directories like compat/ > to aid building for older or broken environments.. > This makes clear difference between software sources > itself (src) and compatibility additions (compat).The compatibility functions (from fake-*.c and dropin.c) are still there, they just moved into src/.> As for FreeBSD itself, I had to change include from global > to local: > > #include "getopt.h"What do you mean by that exactly? If you could send a diff of your changes, I can see if they can be merged. -- Met vriendelijke groet / with kind regards, Guus Sliepen <guus at tinc-vpn.org>
On Fri, Apr 08, 2016 at 02:55:10PM +0200, borg at uu3.net wrote:> There are few reasons why I stick to older OSes. > In case of FreeBSD its my customized Imunes platform > for network simulations...Hm, I just tried FreeBSD 4.11 in a VM and it seems it doesn't support C99 at all. So I guess you already had to install a newer GCC and what not to get things running :)> Anyway, back to root problem: > gcc -std=gnu99 -DHAVE_CONFIG_H -DCONFDIR=\"/etc\" -DLOCALSTATEDIR=\"/var\" > -DFORTIFY_SOURCE=2 -g -O2 -MT tincd.o -MD -MP -MF $depbase.Tpo -c -o tincd.o > tincd.c &&\ > mv -f $depbase.Tpo $depbase.Po > tincd.c:52:20: getopt.h: No such file or directory > tincd.c:102: error: elements of array `long_options' have incomplete type > > Im not very familiar with all those newer fancy build systems (deps tracking), > but for some reason getopt.h is not picked up from src directory at allIt's because the src directory is not in the global search path. This is intended. The problem is more that the local getopt is always compiled in, but the global headers are used. That should be fixed. -- Met vriendelijke groet / with kind regards, Guus Sliepen <guus at tinc-vpn.org> -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: Digital signature URL: <http://www.tinc-vpn.org/pipermail/tinc-devel/attachments/20160408/59c77734/attachment.sig>
Yes, I upgrade to gcc-3.3.6 right away and also add gmake-3.80. Yeah, everyone is moved to C99, I had hard time with quagga too. Luicky, gcc upgrade fixed all problems there. Anyway, im kinda regred sending an email about this now. I added you a lot of work... If this will be too problematic, just leave it as is. No need to bother to cover less that 0.1% uses cases here? I think its time to fork tinc to support my old platforms like I do with everything else these days. Kind Regards, Borg ---------- Original message ---------- From: Guus Sliepen <guus at tinc-vpn.org> To: tinc-devel at tinc-vpn.org Subject: Re: Commit 68f4ca7 issues Date: Fri, 8 Apr 2016 17:26:57 +0200 Message-ID: <20160408152657.GH3784 at sliepen.org> On Fri, Apr 08, 2016 at 02:55:10PM +0200, borg at uu3.net wrote:> There are few reasons why I stick to older OSes. > In case of FreeBSD its my customized Imunes platform > for network simulations...Hm, I just tried FreeBSD 4.11 in a VM and it seems it doesn't support C99 at all. So I guess you already had to install a newer GCC and what not to get things running :)> Anyway, back to root problem: > gcc -std=gnu99 -DHAVE_CONFIG_H -DCONFDIR=\"/etc\" -DLOCALSTATEDIR=\"/var\" > -DFORTIFY_SOURCE=2 -g -O2 -MT tincd.o -MD -MP -MF $depbase.Tpo -c -o tincd.o > tincd.c &&\ > mv -f $depbase.Tpo $depbase.Po > tincd.c:52:20: getopt.h: No such file or directory > tincd.c:102: error: elements of array `long_options' have incomplete type > > Im not very familiar with all those newer fancy build systems (deps tracking), > but for some reason getopt.h is not picked up from src directory at allIt's because the src directory is not in the global search path. This is intended. The problem is more that the local getopt is always compiled in, but the global headers are used. That should be fixed. -- Met vriendelijke groet / with kind regards, Guus Sliepen <guus at tinc-vpn.org>