aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xconfigure3
-rw-r--r--util-src/GNUmakefile1
-rw-r--r--util-src/makefile2
3 files changed, 5 insertions, 1 deletions
diff --git a/configure b/configure
index 2b58efe5..abb5ffef 100755
--- a/configure
+++ b/configure
@@ -524,7 +524,7 @@ fi
if [ "$IDN_LIBRARY" = "icu" ]
then
IDNA_LIBS="$ICU_FLAGS"
- CFLAGS="$CFLAGS -DUSE_STRINGPREP_ICU"
+ IDNA_FLAGS="-DUSE_STRINGPREP_ICU"
fi
if [ "$IDN_LIBRARY" = "idn" ]
then
@@ -569,6 +569,7 @@ LUA_INCDIR=$LUA_INCDIR
LUA_LIBDIR=$LUA_LIBDIR
LUA_BINDIR=$LUA_BINDIR
IDN_LIB=$IDN_LIB
+IDNA_FLAGS=$IDNA_FLAGS
IDNA_LIBS=$IDNA_LIBS
OPENSSL_LIBS=$OPENSSL_LIBS
CFLAGS=$CFLAGS
diff --git a/util-src/GNUmakefile b/util-src/GNUmakefile
index 054c9201..e9e06355 100644
--- a/util-src/GNUmakefile
+++ b/util-src/GNUmakefile
@@ -24,6 +24,7 @@ install: $(ALL)
clean:
rm -f $(ALL) $(patsubst %.so,%.o,$(ALL))
+encodings.o: CFLAGS+=$(IDNA_FLAGS)
encodings.so: LDLIBS+=$(IDNA_LIBS)
hashes.so: LDLIBS+=$(OPENSSL_LIBS)
diff --git a/util-src/makefile b/util-src/makefile
index 700633b4..2db415df 100644
--- a/util-src/makefile
+++ b/util-src/makefile
@@ -23,6 +23,8 @@ install: $(ALL)
clean:
rm -f $(ALL) $(patsubst %.so,%.o,$(ALL))
+encodings.o: encodings.c
+ $(CC) $(CFLAGS) $(IDNA_FLAGS) -c -o $@ $<
encodings.so: encodings.o
$(LD) $(LDFLAGS) -o $@ $< $(LDLIBS) $(IDNA_LIBS)