summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2017-04-12 10:51:07 +0200
committerArtyom V. Poptsov <poptsov.artyom@gmail.com>2017-04-23 07:51:52 +0300
commit25201ac2d5c113f1626108353c7e3cf1916963cb (patch)
tree5f12f0d28a55f24fa903260057e6df41f8bc7174 /tests
parenttests: Use 'inet-ntop' instead of 'inet-ntoa'. (diff)
downloadguile-ssh-25201ac2d5c113f1626108353c7e3cf1916963cb.tar.gz
build: Allow VPATH builds.
This fixes builds where $(builddir) != $(srcdir). * examples/Makefile.am (.in): Use $(MKDIR_P) to make the target's parent directories. * tests/common.scm (%topbuilddir): New variable. * tests/sssh-ssshd.scm (*ssshd-cmd*, *sssh-cmd*): Use it instead of %TOPDIR. Signed-off-by: Artyom V. Poptsov <poptsov.artyom@gmail.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/common.scm2
-rw-r--r--tests/sssh-ssshd.scm4
2 files changed, 4 insertions, 2 deletions
diff --git a/tests/common.scm b/tests/common.scm
index 451a374..c71b85e 100644
--- a/tests/common.scm
+++ b/tests/common.scm
@@ -31,6 +31,7 @@
#:use-module (ssh message)
#:export (;; Variables
%topdir
+ %topbuilddir
%knownhosts
%config
%addr
@@ -65,6 +66,7 @@
(define %topdir (getenv "abs_top_srcdir"))
+(define %topbuilddir (getenv "abs_top_builddir"))
(define %addr "127.0.0.1")
(define *port* 12400)
diff --git a/tests/sssh-ssshd.scm b/tests/sssh-ssshd.scm
index c7d1738..18cba32 100644
--- a/tests/sssh-ssshd.scm
+++ b/tests/sssh-ssshd.scm
@@ -39,7 +39,7 @@
(define *ssshd-cmd*
(string-append
- %topdir "/examples/ssshd.scm --detach"
+ %topbuilddir "/examples/ssshd.scm --detach"
" --pid-file=" *srv-pid-file*
" --port=" (number->string *srv-port*)
" --rsakey=" %rsakey
@@ -47,7 +47,7 @@
(define *sssh-cmd*
(string-append
- %topdir "/examples/sssh.scm"
+ %topbuilddir "/examples/sssh.scm"
" --identity-file=" %rsakey
" --port=" (number->string *srv-port*)
" --known-hosts-file=" %knownhosts