*.so
*.d
test-load.tcl
+debian-substvars
*+tcmdif.[ch]
debian/files
debian/libtcl-chiark-1
default: all
-clean all:
+clean all debian-substvars:
set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d $@; done
# To find undefined symbols when implementing, for example:
base+tcmdif.h: $(BASE_TCT) $(TCMDIFGEN)
$(TCMDIFGEN) -wh -o$@ $<
+debian-substvars: all
+
include shlib.make
include final.make
@set -x; LD_LIBRARY_PATH=$(subst $(space),:,$(strip $(OTHER_DIRS)))$${LD_LIBRARY_PATH+:}$${LD_LIBRARY_PATH} \
tclsh$(TCL_VERSION) test-load.tcl
+debian-substvars: all
+ set -e; d=`pwd`; cd ..; \
+ dpkg-shlibdeps -T"$$d"/$@ "$$d"/$(SHLIB).so
+
include $(BASE_DIR)/final.make
--- /dev/null
+#!/bin/bash
+set -e
+
+dt=debian/tests
+
+rm -rf $dt
+mkdir -p $dt
+
+exec 4>$dt/control.new
+
+for sv in */debian-substvars; do
+ d=${sv%/*}
+ if ! test -e "$sv"; then continue; fi
+ make -C "$d" test-load.tcl
+ printf "%s..." $d
+ for v in "$@"; do
+ t=$d--$v
+ printf " %s" $v
+ exec 3>$dt/$t
+ echo >&3 "#!/usr/bin/tclsh$v"
+ cat >&3 "$d"/test-load.tcl
+ echo >&3 'set t {'"$d"'/runtest.tcl}'
+ echo >&3 'if {[file exists $t]} { source $t }'
+ chmod +x $dt/$t
+ echo >&4 "Tests: $t"
+ sed "s/^shlibs:Depends=/Depends: tcl$v, /" >&4 $sv
+ echo >&4
+ done
+ echo
+done
+
+mv $dt/control.new $dt/control
tclh:=$(firstword $(wildcard /usr/include/tcl8.*/tcl.h))
tclversion:=$(patsubst /usr/include/tcl%/tcl.h,%,$(tclh))
+tcl_versions= 8.4 8.5 8.6 8.7 8.8
+
march := $(shell dpkg-architecture -q DEB_HOST_MULTIARCH)
libsubdir = /$(march)
$(checkdir)
dh_testroot
+debian/tests/control: debian/regenerate-autopkgtests debian/rules
+ $(MAKE) debian-substvars
+ $< $(tcl_versions)
+
.PHONY: binary binary-arch binary-indep clean checkroot