Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct build env #360

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions cmake/FindIntl.cmake
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# This file comes from https://github.com/Kitware/CMake/blob/master/Modules/FindIntl.cmake
# It is needed for cmake < 3.2.0 which does not have it.
# When cmake 3.0.2 (Debian jessie version) will really be outdated, we will be able to
# delete this file and bump cmake version in CMakeLists.txt and INSTALL.md.

# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.

Expand Down
15 changes: 12 additions & 3 deletions test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,24 @@
cd "$(dirname "$0")"

# Failed tests can leave dangling mounts behind.
for i in $(mount | grep -e "/tmp/encfs-reverse-tests-\|/tmp/encfs-tests-" | cut -f3 -d" "); do
todel+=("")
for i in $(mount | grep "/tmp/encfs-tests-" | cut -f3 -d" "); do
echo "Warning: unmounting leftover filesystem: $i"
fusermount -u $i || true
if which fusermount >/dev/null 2>&1
then
fusermount -u $i || true
else
umount -f $i || true
fi
parent=$(echo $i | grep "/tmp/encfs-tests-" | sed 's+\(/tmp/encfs-tests-[^/]*\).*+\1+')
todel+=("$parent")
done
rm -rf ${todel[@]}

set -x

# This is very noisy so run it silently at first. Run it again with
# output if the first run fails.
./build/checkops &> /dev/null || ./build/checkops
./build/checkops >/dev/null 2>&1 || ./build/checkops

perl -MTest::Harness -e '$$Test::Harness::debug=1; runtests @ARGV;' tests/*.t.pl
2 changes: 1 addition & 1 deletion tests/normal.t.pl
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ sub runTests
# Create a new empty working directory
sub newWorkingDir
{
our $workingDir = mkdtemp("$tempDir/encfs-tests-XXXX")
our $workingDir = mkdtemp("$tempDir/encfs-tests-normal-XXXX")
|| BAIL_OUT("Could not create temporary directory");

our $raw = "$workingDir/raw";
Expand Down
2 changes: 1 addition & 1 deletion tests/reverse.t.pl
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
# Create a new empty working directory
sub newWorkingDir
{
our $workingDir = mkdtemp("$tempDir/encfs-reverse-tests-XXXX")
our $workingDir = mkdtemp("$tempDir/encfs-tests-reverse-XXXX")
|| BAIL_OUT("Could not create temporary directory");

our $plain = "$workingDir/plain";
Expand Down