luvit/luvit — Issue #34: compilation fails on windows ( mingw )
Author: leite
Created: 2011-12-02 19:09:26+00:00
State: open

i just clone Luvit and try to install ... and ended with an error

```shell
C:\dev\luvit>make CC=gcc
git submodule update --init deps/luajit
make -C deps/luajit
make[1]: Entering directory `C:/dev/luvit/deps/luajit'
==== Building LuaJIT 2.0.0-beta8 ====
make -C src
make[2]: Entering directory `C:/dev/luvit/deps/luajit/src'
make[2]: Nothing to be done for `default'.
make[2]: Leaving directory `C:/dev/luvit/deps/luajit/src'
==== Successfully built LuaJIT 2.0.0-beta8 ====
make[1]: Leaving directory `C:/dev/luvit/deps/luajit'
mkdir -p build
gcc -Wall -Werror -c src/luv_udp.c -o build/luv_udp.o -Ideps/http-parser -Ideps/
uv/include -Ideps/luajit/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
In file included from src/luv_udp.c:4:0:
src/luv_udp.h:12:30: fatal error: inet_net_pton.h: No such file or directory
compilation terminated.
make: *** [build/luv_udp.o] Error 1

```

i read about the hack ... and comment the lines 12, 13 of luv_udp.h

```C
# include
# include
```

i tried again ...

```shell
C:\dev\luvit>make CC=gcc
git submodule update --init deps/luajit
make -C deps/luajit
make[1]: Entering directory `C:/dev/luvit/deps/luajit'
==== Building LuaJIT 2.0.0-beta8 ====
make -C src
make[2]: Entering directory `C:/dev/luvit/deps/luajit/src'
make[2]: Nothing to be done for `default'.
make[2]: Leaving directory `C:/dev/luvit/deps/luajit/src'
==== Successfully built LuaJIT 2.0.0-beta8 ====
make[1]: Leaving directory `C:/dev/luvit/deps/luajit'
mkdir -p build
gcc -Wall -Werror -c src/luv_udp.c -o build/luv_udp.o -Ideps/http-parser -Ideps/
uv/include -Ideps/luajit/src -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
src/luv_udp.c: In function 'luv_udp_getsockname':
src/luv_udp.c:112:5: error: implicit declaration of function 'ares_inet_ntop' [-
Werror=implicit-function-declaration]
cc1.exe: all warnings being treated as errors

make: *** [build/luv_udp.o] Error 1

```

any idea?

nice work, i'm so happy to see a web project like that, keep improving!

i have some work on a cookie / session library in C, i wish i could add it to luvit.