diff --git i/libsecret/meson.build w/libsecret/meson.build
index 0c448b9..c0138d2 100644
--- i/libsecret/meson.build
+++ w/libsecret/meson.build
@@ -185,6 +185,7 @@ pkg.generate(description: 'GObject bindings for Secret Service API (Unstable)',
 test_cflags = [
   libsecret_cflags,
   '-DSRCDIR="@0@"'.format(meson.source_root()),
+  '-DSECRET_WITH_UNSTABLE',
 ]
 
 mock_service_lib = library('mock-service',
