summarylogtreecommitdiffstats
path: root/meson-test-release.diff
diff options
context:
space:
mode:
authorDaniel Peukert2021-03-14 17:40:24 +0100
committerDaniel Peukert2021-03-14 17:40:24 +0100
commit6cc22001531b77784766934349c88c0dd42b0252 (patch)
tree0c817af8e3d153e46ca90c17feff4beb753f1694 /meson-test-release.diff
parent0ce33852639c4ff39267bce3bf80ea9e30468dce (diff)
downloadaur-6cc22001531b77784766934349c88c0dd42b0252.tar.gz
Fix up meson & cargo arguments for spot-client
Diffstat (limited to 'meson-test-release.diff')
-rw-r--r--meson-test-release.diff40
1 files changed, 40 insertions, 0 deletions
diff --git a/meson-test-release.diff b/meson-test-release.diff
new file mode 100644
index 000000000000..59b6bfbbb251
--- /dev/null
+++ b/meson-test-release.diff
@@ -0,0 +1,40 @@
+diff --git a/build-aux/test.sh b/build-aux/test.sh
+index f8ca912..f3b9e8f 100644
+--- a/build-aux/test.sh
++++ b/build-aux/test.sh
+@@ -2,10 +2,19 @@
+
+ export SRC="$1"
+ export CARGO_TARGET_DIR="$2"/target
+-export OFFLINE="$3"
++export BUILDTYPE="$3"
++export OFFLINE="$4"
++
++echo $BUILDTYPE
++
++if [[ $BUILDTYPE = "release" ]]; then
++ PROFILE_ARG="--release"
++else
++ PROFILE_ARG="--verbose"
++fi
+
+ if [[ $OFFLINE = "true" ]]; then
+ export CARGO_HOME="$SRC"/cargo
+ fi
+
+-cargo test --manifest-path "$SRC"/Cargo.toml
+\ No newline at end of file
++cargo test --manifest-path "$SRC"/Cargo.toml "$PROFILE_ARG"
+\ No newline at end of file
+diff --git a/src/meson.build b/src/meson.build
+index 93d7387..909e9d6 100644
+--- a/src/meson.build
++++ b/src/meson.build
+@@ -140,6 +140,7 @@ test('Unit tests',
+ args: [
+ meson.source_root(),
+ meson.build_root(),
++ get_option('buildtype'),
+ get_option('offline') ? 'true' : 'false'
+ ]
+ )