diff --git a/pressure-vessel/launch.c b/pressure-vessel/launch.c index 7d8ad44bdfc8b75b3d5e0831c8a5ec21d5b9e617..d0c337995b97b5e26ad1bcd9001a88e61a9082df 100644 --- a/pressure-vessel/launch.c +++ b/pressure-vessel/launch.c @@ -1078,14 +1078,6 @@ main (int argc, g_debug ("Using \"%s\" as /app instead of runtime", opt_app_path); g_assert (api == &subsandbox_api); - - if (g_getenv ("PRESSURE_VESSEL_FLATPAK_PR4018") == NULL) - { - glnx_throw (error, - "--app-path requires an experimental branch of Flatpak"); - goto out; - } - check_portal_version ("app-path", 6); if (opt_app_path[0] == '\0') @@ -1113,14 +1105,6 @@ main (int argc, g_debug ("Using %s as /usr instead of runtime", opt_usr_path); g_assert (api == &subsandbox_api); - - if (g_getenv ("PRESSURE_VESSEL_FLATPAK_PR4018") == NULL) - { - glnx_throw (error, - "--usr-path requires an experimental branch of Flatpak"); - goto out; - } - check_portal_version ("usr-path", 6); handle = path_to_handle (fd_list, opt_usr_path, home_realpath, diff --git a/pressure-vessel/wrap-flatpak.c b/pressure-vessel/wrap-flatpak.c index cb2e86e4a769e171bbd146d39a0ab41ca479129e..fb0a9b8ef217ee028f2bc0a60ed0185649a74896 100644 --- a/pressure-vessel/wrap-flatpak.c +++ b/pressure-vessel/wrap-flatpak.c @@ -149,11 +149,18 @@ pv_wrap_check_flatpak (const char *tools_dir, "pressure-vessel-launch", NULL); + if (flatpak_version != NULL && strverscmp (flatpak_version, "1.11.0") >= 0) + { + g_warning ("Using experimental Flatpak sub-sandboxing " + "(requires Flatpak 1.11.x commit 1.10.1-65-g3ebf371f " + "or later)"); + subsandbox = get_subsandbox_adverb (launch_executable); + } /* Deliberately not documented: only people who are in a position * to run their own modified versions of Flatpak and pressure-vessel * should be using this, and those people can find this in the * source code */ - if (g_getenv ("PRESSURE_VESSEL_FLATPAK_PR4018") != NULL) + else if (g_getenv ("PRESSURE_VESSEL_FLATPAK_PR4018") != NULL) { g_warning ("Assuming your version of Flatpak contains unmerged " "changes (#4018, #4125, #4126, #4093)");