Can't build gettext 0.18_1

Hello.. I am trying to update a server of mine and can't seem to upgrade gettext. I've updated my ports and even did a fresh 'portsnap fetch extract' on a newly created /usr/ports directory.

I also tried rebuilding the only dependencies gettext required (libiconv and libtool).

No matter what I do, I get the same exact error.

(gettext-0.17_1-> 0.18_1)

Code:
uname -a
FreeBSD mail.digitalfoo.net 7.2-RELEASE FreeBSD 7.2-RELEASE #2: Thu May 28 13:31:46 UTC 2009     root@:/usr/src/sys/i386/compile/DELL_SERVER  
i386

Code:
 -fno-strict-aliasing -pipe -c safe-write.c -o safe-write.o >/dev/null 2>&1
/bin/sh /usr/local/bin/libtool  --tag=CC    --mode=compile cc -std=gnu99 -DHAVE_CONFIG_H -DEXEEXT=\"\" -DEXEEXT=\"\"  -DEXEEXT=\"\"  -I. -I..  
-I../intl -I../intl  -I.. -I.. -DDEPENDS_ON_LIBICONV=1  -DDEPENDS_ON_LIBINTL=1 -DLIBXML_STATIC -I../intl     -I./libcroco   -
I/usr/local/include   -O2 -fno-strict-aliasing -pipe -c -o spawn_faction_addclose.lo spawn_faction_addclose.c
libtool: compile:  cc -std=gnu99 -DHAVE_CONFIG_H -DEXEEXT=\"\" -DEXEEXT=\"\" -DEXEEXT=\"\" -I. -I.. -I../intl -I../intl -I.. -I.. -
DDEPENDS_ON_LIBICONV=1 -DDEPENDS_ON_LIBINTL=1 -DLIBXML_STATIC -I../intl -I./libcroco -I/usr/local/include -O2 -fno-strict-aliasing -pipe -c 
spawn_faction_addclose.c  -fPIC -DPIC -o .libs/spawn_faction_addclose.o
spawn_faction_addclose.c: In function 'posix_spawn_file_actions_addclose':
spawn_faction_addclose.c:45: error: request for member '_used' in something not a structure or union
spawn_faction_addclose.c:45: error: request for member '_allocated' in something not a structure or union
spawn_faction_addclose.c:51: error: request for member '_actions' in something not a structure or union
spawn_faction_addclose.c:51: error: request for member '_used' in something not a structure or union
spawn_faction_addclose.c:56: error: request for member '_used' in something not a structure or union
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools/gnulib-lib.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools/gnulib-lib.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.
*** Error code 1

Stop in /usr/ports/devel/gettext.
 
Select text and use # to become like this:
Code:
-fno-strict-aliasing -pipe -c safe-write.c -o safe-write.o >/dev/null 2>&1
/bin/sh /usr/local/bin/libtool --tag=CC --mode=compile cc -std=gnu99 -DHAVE_CONFIG_H -DEXEEXT=\"\" -DEXEEXT=\"\" -DEXEEXT=\"\" -I. -I.. -I../intl -I../intl -I.. -I.. -DDEPENDS_ON_LIBICONV=1 -DDEPENDS_ON_LIBINTL=1 -DLIBXML_STATIC -I../intl -I./libcroco -I/usr/local/include -O2 -fno-strict-aliasing -pipe -c -o spawn_faction_addclose.lo spawn_faction_addclose.c
libtool: compile: cc -std=gnu99 -DHAVE_CONFIG_H -DEXEEXT=\"\" -DEXEEXT=\"\" -DEXEEXT=\"\" -I. -I.. -I../intl -I../intl -I.. -I.. -DDEPENDS_ON_LIBICONV=1 -DDEPENDS_ON_LIBINTL=1 -DLIBXML_STATIC -I../intl -I./libcroco -I/usr/local/include -O2 -fno-strict-aliasing -pipe -c spawn_faction_addclose.c -fPIC -DPIC -o .libs/spawn_faction_addclose.o
spawn_faction_addclose.c: In function 'posix_spawn_file_actions_addclose':
spawn_faction_addclose.c:45: error: request for member '_used' in something not a structure or union
spawn_faction_addclose.c:45: error: request for member '_allocated' in something not a structure or union
spawn_faction_addclose.c:51: error: request for member '_actions' in something not a structure or union
spawn_faction_addclose.c:51: error: request for member '_used' in something not a structure or union
spawn_faction_addclose.c:56: error: request for member '_used' in something not a structure or union
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools/gnulib-lib.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools/gnulib-lib.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18/gettext-tools.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.
*** Error code 1

Stop in /usr/ports/devel/gettext.
to be easier for reading.
Try
Code:
pkg_add -r gettext
Read this. Maybe help: http://forums.freebsd.org/showthread.php?t=15759
 
I just build gettext as part of a bigger build and it built just fine. It doesn't look like the OP has any special compiler options turned on in /etc/make.conf. One thing I can think of is not having the correct version of libtool installed. Make sure it's devel/libtool22.
 
Thanks for the comments... and the nudge to post correctly ;)

libtool22 is installed (and reinstalled, etc!)

The only thing I have in make.conf is
Code:
CLAMAVUSER=vscan
CLAMAVGROUP=vscan
OVERRIDE_LINUX_BASE_PORT=f8
OVERRIDE_LINUX_NONBASE_PORTS=f8
# added by use.perl 2009-11-07 13:14:23
PERL_VERSION=5.8.9
I have also tried the pkg_add route, but gettext-17 is what is there and is also what is installed.

And you are correct.. I have built gettext no problem on my other servers as well as in a VM... never coming to the same conclusion.

This is just a strange one :-/ I've never really encountered such a stubborn compile with _ports_. OF COURSE it had to be such a foundation package hehe
 
1... copy the two old .so. to /usr/local/lib/compat
2... in /gettext/ "touch __remove_stale_so_files.REMIND"
3... pkg_delete -f /var/db/pkg/gettext- [something] | tee -a gettext.deps
4... /bin/rm -rf work && make install
...
Here, the commands above are mostly coincidental, but the reason
for this post is, I had to deinstall gettext before it would
build. You might be facing the same issue.
 
jb_fvwm2 said:
1... copy the two old .so. to /usr/local/lib/compat
2... in /gettext/ "touch __remove_stale_so_files.REMIND"
3... pkg_delete -f /var/db/pkg/gettext- [something] | tee -a gettext.deps
4... /bin/rm -rf work && make install

hm, I tried following your suggestion (and plain reinstalling gettext)... but no luck.

jb_fvwm2: Did you get the same error I am experiencing?

Any debugging ideas? I have looked at the lines of code in question, but I don't see an immediate remedy. Thanks for all your comments so far.
 
no luck?
...
some things I try...
...
deinstalling the port first (sometimes pkg_create first)
building in sh or bash rather than the default shell
rebuilding dependencies
removing non default options
renaming /etc/make.conf
...
 
>>> Assuming you're using 7.x <<<<
This error is caused by a rogue /usr/include/spawn.h which might be left over if you previously tried to upgrade to 8.x and then downgraded back to 7.x later.
Remove /usr/include/spawn.h and gettext will build again.
Don't remove /usr/include/spawn.h if you're on 8.x!
 
fforu said:
>>> Assuming you're using 7.x <<<<
This error is caused by a rogue /usr/include/spawn.h which might be left over if you previously tried to upgrade to 8.x and then downgraded back to 7.x later.
Remove /usr/include/spawn.h and gettext will build again.
Don't remove /usr/include/spawn.h if you're on 8.x!

Awesome... you are correct. I had tried the remote upgrade to 8 and failed.
 
I have the same problem:

%uname -a
Code:
FreeBSD vhost 7.4-RELEASE-p12 FreeBSD 7.4-RELEASE-p12 #0: Thu Apr 11 21:42:08 UTC 2013     root@vhost:/usr/obj/usr/src/sys/REGENERIC  amd64
%pkg_info
Code:
compat6x-amd64-6.4.604000.200810_3
dialog4ports-0.1.3
libiconv-1.14_1
libsigsegv-2.10
libtool-2.4.2
perl-threaded-5.14.2_3
xz-5.0.4
Code:
libtool: compile:  cc -std=gnu99 -DHAVE_CONFIG_H -DEXEEXT=\"\" -DEXEEXT=\"\" -DEXEEXT=\"\" -I. -I.. -I../intl -I../intl -I.. -I.. -DDEPENDS_ON_LIBICONV=1 -DDEPENDS_ON_LIBINTL=1 -DLIBXML_STATIC -I../intl -I./libcroco -I/usr/local/include -O2 -fno-strict-aliasing -pipe -c execute.c  -fPIC -DPIC -o .libs/execute.o
In file included from execute.c:47:
./spawn.h:27:25: error: spawn.h: No such file or directory
In file included from execute.c:47:
./spawn.h:542: error: expected ';', ',' or ')' before '*' token
./spawn.h:576: error: expected ')' before '*' token
./spawn.h:601: error: expected ')' before '*' token
./spawn.h:730: error: expected ')' before '*' token
./spawn.h:794: error: expected ')' before '*' token
./spawn.h:1014: error: expected ')' before '*' token
./spawn.h:1043: error: expected ')' before '*' token
./spawn.h:1077: error: expected ')' before '*' token
./spawn.h:1111: error: expected ')' before '*' token
./spawn.h:1143: error: expected ')' before '*' token
execute.c: In function 'execute':
execute.c:204: error: 'posix_spawn_file_actions_t' undeclared (first use in this function)
execute.c:204: error: (Each undeclared identifier is reported only once
execute.c:204: error: for each function it appears in.)
execute.c:204: error: expected ';' before 'actions'
execute.c:206: error: 'posix_spawnattr_t' undeclared (first use in this function)
execute.c:206: error: expected ';' before 'attrs'
execute.c:218: warning: implicit declaration of function 'posix_spawn_file_actions_init'
execute.c:218: error: 'actions' undeclared (first use in this function)
execute.c:221: warning: implicit declaration of function 'posix_spawn_file_actions_addopen'
execute.c:239: warning: implicit declaration of function 'posix_spawnattr_init'
execute.c:239: error: 'attrs' undeclared (first use in this function)
execute.c:241: warning: implicit declaration of function 'posix_spawnattr_setsigmask'
execute.c:244: warning: implicit declaration of function 'posix_spawnattr_setflags'
execute.c:247: warning: implicit declaration of function 'posix_spawnp'
execute.c:253: warning: implicit declaration of function 'posix_spawn_file_actions_destroy'
execute.c:255: warning: implicit declaration of function 'posix_spawnattr_destroy'
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.1.1/gettext-tools/gnulib-lib.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.1.1/gettext-tools/gnulib-lib.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.1.1/gettext-tools.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.1.1/gettext-tools.
*** Error code 1

Stop in /usr/ports/devel/gettext/work/gettext-0.18.1.1.
*** Error code 1

Stop in /usr/ports/devel/gettext.
%
 
BTW, the topic is almost three years old, and dead for about as long.
 
I'm also using FreeBSD 7.4, and didn't notice that that release is no longer maintained, and encountered the same problem as you. I've resolved it by make ac_cv_header_spawn_h=no. I'm not sure why its configure script considers that <spawn.h> exists:
Code:
checking for sched.h... yes
checking for signal.h... (cached) yes
[color="Red"]checking for spawn.h... (cached) yes[/color]
checking stdarg.h usability... yes
 
Back
Top