mirror of
https://github.com/swaywm/sway.git
synced 2025-11-08 13:29:50 -05:00
Fix build on FreeBSD
- Make sure CMake always finds absolute paths for Cairo, Pango and GdkPixbuf - Add forgotten json-c include path to swaymsg/CMakeLists.txt - Disable -Werror because of assert warnings - Add correct /proc/pid/file path for FreeBSD - Use libepoll-shim on FreeBSD - Only use Linux capabilities on, well, Linux
This commit is contained in:
parent
d93e53fd4b
commit
da26d69cb1
11 changed files with 127 additions and 103 deletions
|
|
@ -28,7 +28,11 @@ struct command_policy *alloc_command_policy(const char *command) {
|
|||
}
|
||||
|
||||
enum secure_feature get_feature_policy(pid_t pid) {
|
||||
#ifdef __FreeBSD__
|
||||
const char *fmt = "/proc/%d/file";
|
||||
#else
|
||||
const char *fmt = "/proc/%d/exe";
|
||||
#endif
|
||||
int pathlen = snprintf(NULL, 0, fmt, pid);
|
||||
char *path = malloc(pathlen + 1);
|
||||
snprintf(path, pathlen + 1, fmt, pid);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue