[luatex] compiling on MINIX3

Reviczky, Adam adam.reviczky at kcl.ac.uk
Fri Jul 1 19:47:35 CEST 2011


> > Any chance we can change build.sh?
> 
> Done (that was easy).

Thanks.

> > -#if defined(_AIX)
> > +#if defined(_AIX) || defined(__minix)
> >   #include<strings.h>  /* for strcasecmp */
> >   #endif
> 
> Ok, but have not applied that yet, because that is not the end
> of it anyway.

Yes, I was thinking the same.

> This is somewhat more tricky, as it seems that setsockopt() in minix is
> far from complete, so lots of #defines are missing from the headers.
> 
> You could try (just for the sake of testing compilation) to change the
> relevant lines to something like this:
> 
> int opt_dontroute(lua_State *L, p_socket ps)
> {
> #ifdef SO_DONTROUTE
>      return opt_setboolean(L, ps, SOL_SOCKET, SO_DONTROUTE); /* 62 */
> #else
>      return 0;
> #endif
> }


That gives now:

gcc -DHAVE_CONFIG_H -I. -I../../../source/texk/web2c -I./w2c  -DLUASOCKET_DEBUG -I../../../source/texk/web2c/luatexdir/luasocket -I../../../source/texk/web2c/luatexdir/lua51   -g -O2 -MT libluasocket_a-options.o -MD -MP -MF .deps/libluasocket_a-options.Tpo -c -o libluasocket_a-options.o `test -f 'luatexdir/luasocket/src/options.c' || echo '../../../source/texk/web2c/'`luatexdir/luasocket/src/options.c
../../../source/texk/web2c/luatexdir/luasocket/src/options.c: In function 'opt_broadcast':
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:71: error: 'SO_BROADCAST' undeclared (first use in this function)
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:71: error: (Each undeclared identifier is reported only once
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:71: error: for each function it appears in.)
../../../source/texk/web2c/luatexdir/luasocket/src/options.c: In function 'opt_ip_multicast_loop':
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:76: error: 'IP_MULTICAST_LOOP' undeclared (first use in this function)
../../../source/texk/web2c/luatexdir/luasocket/src/options.c: In function 'opt_linger':
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:81: error: storage size of 'li' isn't known
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:93: error: 'SO_LINGER' undeclared (first use in this function)
../../../source/texk/web2c/luatexdir/luasocket/src/options.c: In function 'opt_ip_multicast_ttl':
../../../source/texk/web2c/luatexdir/luasocket/src/options.c:99: error: 'SO_LINGER' undeclared (first use in this function)
gmake: *** [libluasocket_a-options.o] Error 1
strip: 'build/texk/web2c/luatex': No such file
ls: build/texk/web2c/luatex: No such file or directory

Do I need to make a check with all of the values above (eg: SO_BROADCAST, IP_MULTICAST_LOOP and SO_LINGER)?

Best wishes
Adam



More information about the luatex mailing list