Skip to content

Commit

Permalink
Copy config.h approach from wlroots-full.hpp to other public api headers
Browse files Browse the repository at this point in the history
* Otherwise wayfire could use the config.h of an already installed
  wayfire installation and lead to confusing linking issues if the
  options differed (like installed wayfire has xwayland disabled and the
  new build has it enabled).

Signed-off-by: Alfred Wingate <[email protected]>
  • Loading branch information
parona-source committed Mar 18, 2024
1 parent b134f11 commit 65982ed
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
8 changes: 5 additions & 3 deletions src/api/wayfire/unstable/wlr-view-events.hpp
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
#pragma once

#if __has_include(<wayfire/config.h>)
#include <wayfire/config.h>
// WF_USE_CONFIG_H is set only when building Wayfire itself, external plugins
// need to use <wayfire/config.h>
#ifdef WF_USE_CONFIG_H
#include <config.h>
#else
#include "config.h"
#include <wayfire/config.h>
#endif

#include <wayfire/nonstd/wlroots-full.hpp>
Expand Down
8 changes: 5 additions & 3 deletions src/api/wayfire/unstable/xwl-toplevel-base.hpp
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
#pragma once

#if __has_include(<wayfire/config.h>)
#include <wayfire/config.h>
// WF_USE_CONFIG_H is set only when building Wayfire itself, external plugins
// need to use <wayfire/config.h>
#ifdef WF_USE_CONFIG_H
#include <config.h>
#else
#include "config.h"
#include <wayfire/config.h>
#endif

#include <wayfire/nonstd/wlroots-full.hpp>
Expand Down

0 comments on commit 65982ed

Please sign in to comment.