--- a/Makefile.in
+++ b/Makefile.in
-@@ -4,7 +4,7 @@ LIBTCL = -ltcl8.4
+@@ -4,7 +4,8 @@ LIBTCL = -ltcl8.4
CC = @CC@
CPP = @CPP@
CFLAGS = @CFLAGS@
-CPPFLAGS = -D_GNU_SOURCE -I/usr/include/slang @CPPFLAGS@
++AR ?= ar
+CPPFLAGS = -D_GNU_SOURCE @CPPFLAGS@
SHLIBFLAGS= -Wl,--version-script,newt.0.52.ver
VERSION = @VERSION@
-@@ -53,19 +53,19 @@ endif
+@@ -53,19 +54,19 @@ endif
all: $(TARGET) _snackmodule.so
test: test.o $(LIBNEWT)
_snackmodule.so: snackmodule.c $(LIBNEWTSH)
for ver in $(PYTHONVERS) ; do \
-@@ -76,7 +76,7 @@ _snackmodule.so: snackmodule.c $(LIBNE
+@@ -76,13 +77,13 @@ _snackmodule.so: snackmodule.c $(LIBNE
touch $@
whiptail: $(NDIALOGOBJS) $(LIBNEWTSH)
whiptcl.so: $(WHIPTCLOBJS) $(LIBNEWTSH)
$(CC) -shared $(SHCFLAGS) -o whiptcl.so $(WHIPTCLOBJS) -L . -lnewt $(LIBTCL) -lpopt
-@@ -102,12 +102,12 @@ $(SHAREDDIR):
+
+ $(LIBNEWT): $(LIBOBJS)
+- ar rv $@ $^
++ $(AR) rv $@ $^
+
+ newt.o $(SHAREDDIR)/newt.o: newt.c Makefile
+
+@@ -102,12 +103,12 @@ $(SHAREDDIR):
sharedlib: $(LIBNEWTSH)
$(LIBNEWTSH): $(SHAREDDIR) $(SHAREDOBJS)
--- a/Makefile.in
+++ b/Makefile.in
-@@ -50,7 +50,7 @@ else
+@@ -51,7 +51,7 @@ else
TARGET=depend $(PROGS)
endif
test: test.o $(LIBNEWT)
$(CC) $(CFLAGS) -g -o test test.o $(LIBNEWT) $(LIBS)
-@@ -67,14 +67,6 @@ showchars: showchars.o $(LIBNEWT)
+@@ -68,14 +68,6 @@ showchars: showchars.o $(LIBNEWT)
showkey: showkey.o $(LIBNEWT)
$(CC) $(CFLAGS) -g -o showkey showkey.o $(LIBNEWT) $(LIBS)
whiptail: $(NDIALOGOBJS) $(LIBNEWTSH)
$(CC) $(CFLAGS) -g -o whiptail $(NDIALOGOBJS) -L . -lnewt $(LIBS) -lpopt
-@@ -121,17 +113,12 @@ install: $(LIBNEWT) install-sh whiptail
+@@ -122,17 +114,12 @@ install: $(LIBNEWT) install-sh whiptail
make -C po datadir=$(instroot)/$(datadir) install
install -m 644 -D libnewt.pc $(instroot)/$(pkgconfigdir)/libnewt.pc