summaryrefslogtreecommitdiff
path: root/test cases/failing
diff options
context:
space:
mode:
authorXavier Claessens <xavier.claessens@collabora.com>2020-10-31 14:17:24 -0400
committerJussi Pakkanen <jpakkane@gmail.com>2021-01-12 15:51:28 +0000
commitc659be692896f9f36fa46c4955220dc57653f09b (patch)
treee80d0a29af48ec1046c2e8c499739876c67546c4 /test cases/failing
parent4ff020759a3cdedb9d8ff1150ec09313096f6228 (diff)
downloadmeson-c659be692896f9f36fa46c4955220dc57653f09b.tar.gz
Interpreter: Fix nested subsubproject detection
A sub-subproject can be configured directly from `subprojects/foo/subprojects/bar/` in the case `bar` is in the same git repository as `foo` and not downloaded separately into the main project's `subprojects/`. In that case the nested subproject violation code was wrong because it is allowed to have more than one "subprojects" in path (was not possible before Meson 0.56.0). Example: - self.environment.source_dir = '/home/user/myproject' - self.root_subdir = 'subprojects/foo/subprojects/bar' - project_root = '/home/user/myproject/subprojects/foo/subprojects/bar' - norm = '/home/user/myproject/subprojects/foo/subprojects/bar/file.c' We want `norm` path to have `project_root` in its parents and not have `project_root / 'subprojects'` in its parents. In that case we are sure `file.c` is within `bar` subproject.
Diffstat (limited to 'test cases/failing')
-rw-r--r--test cases/failing/62 subproj filegrab/test.json2
-rw-r--r--test cases/failing/63 grab subproj/test.json2
-rw-r--r--test cases/failing/64 grab sibling/test.json2
3 files changed, 3 insertions, 3 deletions
diff --git a/test cases/failing/62 subproj filegrab/test.json b/test cases/failing/62 subproj filegrab/test.json
index dd0d7bbf3..282cb730b 100644
--- a/test cases/failing/62 subproj filegrab/test.json
+++ b/test cases/failing/62 subproj filegrab/test.json
@@ -1,7 +1,7 @@
{
"stdout": [
{
- "line": "test cases/failing/62 subproj filegrab/subprojects/a/meson.build:3:0: ERROR: Sandbox violation: Tried to grab file prog.c from a different subproject."
+ "line": "test cases/failing/62 subproj filegrab/subprojects/a/meson.build:3:0: ERROR: Sandbox violation: Tried to grab file prog.c outside current (sub)project."
}
]
}
diff --git a/test cases/failing/63 grab subproj/test.json b/test cases/failing/63 grab subproj/test.json
index 81479051a..37ebb3501 100644
--- a/test cases/failing/63 grab subproj/test.json
+++ b/test cases/failing/63 grab subproj/test.json
@@ -1,7 +1,7 @@
{
"stdout": [
{
- "line": "test cases/failing/63 grab subproj/meson.build:7:0: ERROR: Sandbox violation: Tried to grab file sub.c from a different subproject."
+ "line": "test cases/failing/63 grab subproj/meson.build:7:0: ERROR: Sandbox violation: Tried to grab file sub.c from a nested subproject."
}
]
}
diff --git a/test cases/failing/64 grab sibling/test.json b/test cases/failing/64 grab sibling/test.json
index 1604d47bf..bd609ec19 100644
--- a/test cases/failing/64 grab sibling/test.json
+++ b/test cases/failing/64 grab sibling/test.json
@@ -1,7 +1,7 @@
{
"stdout": [
{
- "line": "test cases/failing/64 grab sibling/subprojects/a/meson.build:3:0: ERROR: Sandbox violation: Tried to grab file sneaky.c from a different subproject."
+ "line": "test cases/failing/64 grab sibling/subprojects/a/meson.build:3:0: ERROR: Sandbox violation: Tried to grab file sneaky.c outside current (sub)project."
}
]
}