mirror of
https://github.com/ntop/n2n.git
synced 2024-09-19 00:21:11 +02:00
Fix the building the win32 subdir.
It looks like the github windows build environment is not correctly inheriting environment variables. Which is strange, as that has not been changed with the recent updates. Include the vars directly as a workaround (and plan to refactor later)
This commit is contained in:
parent
9de98c2bb0
commit
1accc76ad3
|
@ -51,6 +51,7 @@ typedef int ssize_t;
|
|||
typedef unsigned long in_addr_t;
|
||||
|
||||
#include "n2n_win32.h"
|
||||
// FIXME - the above include is from a different subdir
|
||||
|
||||
#endif /* #if defined(_MSC_VER) || defined(__MINGW32__) */
|
||||
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
cat >config.mak <<EOF
|
||||
CC=gcc
|
||||
AR=ar
|
||||
CFLAGS=$CFLAGS
|
||||
LDFLAGS=$LDFLAGS
|
||||
CFLAGS=$CFLAGS -g -O2 -I./include
|
||||
LDFLAGS=$LDFLAGS -L.
|
||||
N2N_LIBS_EXTRA=$LDLIBS
|
||||
EOF
|
||||
|
||||
|
|
|
@ -2,14 +2,20 @@
|
|||
# This is not a standalone makefile, it must be called from the toplevel
|
||||
# makefile to inherit the correct environment
|
||||
|
||||
# The vars included here should be part of the environment.
|
||||
# TODO - refactor this and debug why they need to be included for windows
|
||||
include ../config.mak
|
||||
|
||||
DEBUG?=-g3
|
||||
|
||||
HEADERS=$(wildcard include/*.h)
|
||||
CFLAGS+=-I../include
|
||||
LDLIBS+=-ln2n
|
||||
|
||||
ifeq ($(CONFIG_TARGET),mingw)
|
||||
CFLAGS+=-I../win32
|
||||
LDLIBS+=-lnetapi32
|
||||
LDLIBS+=$(abspath ../win32/n2n_win32.a)
|
||||
LDLIBS+=-lnetapi32 -lws2_32 -liphlpapi
|
||||
endif
|
||||
CFLAGS+=$(DEBUG)
|
||||
LDFLAGS+=-L..
|
||||
|
|
|
@ -2,7 +2,11 @@
|
|||
# This is not a standalone makefile, it must be called from the toplevel
|
||||
# makefile to inherit the correct environment
|
||||
|
||||
CFLAGS+=-I../include
|
||||
# The vars included here should be part of the environment.
|
||||
# TODO - refactor this and debug why they need to be included for windows
|
||||
include ../config.mak
|
||||
|
||||
CFLAGS+=-I../include -I.
|
||||
LDFLAGS+=-L..
|
||||
|
||||
.PHONY: all clean install
|
||||
|
|
Loading…
Reference in New Issue
Block a user