Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitd78ba82

Browse files
authored
Merge pull requestmpartel#45 from dandedrick/fix-out-of-place-build
tests: fix building out of place
2 parents10ac49f +37380cb commitd78ba82

File tree

4 files changed

+15
-8
lines changed

4 files changed

+15
-8
lines changed

‎tests/internals/Makefile.am‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11

22
noinst_HEADERS = test_common.h
33
noinst_PROGRAMS = test_internals test_rate_limiter
4-
test_internals_SOURCES = test_internals.c test_common.c$(top_builddir)/src/misc.c
5-
test_rate_limiter_SOURCES = test_rate_limiter.c test_common.c$(top_builddir)/src/rate_limiter.c
4+
test_internals_SOURCES = test_internals.c test_common.c$(top_srcdir)/src/misc.c
5+
test_rate_limiter_SOURCES = test_rate_limiter.c test_common.c$(top_srcdir)/src/rate_limiter.c
66

7-
test_internals_CPPFLAGS = ${my_CPPFLAGS} ${fuse_CFLAGS} -I. -I$(top_builddir)/src
7+
test_internals_CPPFLAGS = ${my_CPPFLAGS} ${fuse_CFLAGS} -I. -I$(top_srcdir)/src
88
test_internals_CFLAGS = ${my_CFLAGS}
99
test_internals_LDADD = ${my_LDFLAGS}
1010

11-
test_rate_limiter_CPPFLAGS = ${my_CPPFLAGS} ${fuse_CFLAGS} -I. -I$(top_builddir)/src
11+
test_rate_limiter_CPPFLAGS = ${my_CPPFLAGS} ${fuse_CFLAGS} -I. -I$(top_srcdir)/src
1212
test_rate_limiter_CFLAGS = ${my_CFLAGS}
1313
test_rate_limiter_LDADD = ${my_LDFLAGS}
1414

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
#!/bin/sh
2-
cd`dirname"$0"`
2+
if [!-x ./test_internals ];then
3+
cd`dirname"$0"`
4+
fi
35
valgrind --error-exitcode=100 ./test_internals
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
#!/bin/sh
2-
cd`dirname"$0"`
2+
if [!-x ./test_rate_limiter ];then
3+
cd`dirname"$0"`
4+
fi
35
valgrind --error-exitcode=100 ./test_rate_limiter

‎tests/test_bindfs.rb‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@
1818
# along with bindfs. If not, see <http://www.gnu.org/licenses/>.
1919
#
2020

21-
require'./common.rb'
21+
# if we are being run by make check it will set srcdir and we should use it
22+
localsrc_path=ENV['srcdir'] ||'.'
23+
24+
requirelocalsrc_path +'/common.rb'
2225

2326
includeErrno
2427

@@ -39,7 +42,7 @@ def chown(user, group, list)
3942
$nobody_gid=nobody_gid=Etc.getpwnam('nobody').gid
4043
$nobody_group=nobody_group=Etc.getgrgid(nobody_gid).name
4144

42-
$tests_dir=File.dirname(File.realpath(__FILE__))
45+
$tests_dir=File.realpath('.')
4346

4447

4548
testenv("")do

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp