Commit bc003c02 authored by Martin Flöser's avatar Martin Flöser

Add cmake check whether sys/sysmacros.h exists

Unfortunately 9ada8bac failed to compile
on FreeBSD due to the header not existing. So we need to check the
existance and properly guard with ifdef.
parent 9ada8bac
......@@ -337,6 +337,7 @@ check_include_file("linux/fb.h" HAVE_LINUX_FB_H)
add_feature_info("linux/fb.h"
HAVE_LINUX_FB_H
"Required for the fbdev backend")
check_include_file("sys/sysmacros.h" HAVE_SYS_SYSMACROS_H)
########### global ###############
set(kwin_effects_dbus_xml ${CMAKE_CURRENT_SOURCE_DIR}/org.kde.kwin.Effects.xml)
......
......@@ -21,6 +21,7 @@
#cmakedefine01 HAVE_PR_SET_PDEATHSIG
#cmakedefine01 HAVE_SYS_PROCCTL_H
#cmakedefine01 HAVE_PROC_TRACE_CTL
#cmakedefine01 HAVE_SYS_SYSMACROS_H
#cmakedefine01 HAVE_BREEZE_DECO
#cmakedefine01 HAVE_UDEV
#if HAVE_BREEZE_DECO
......
......@@ -29,7 +29,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include <QDBusMetaType>
#include <sys/stat.h>
#include <config-kwin.h>
#if HAVE_SYS_SYSMACROS_H
#include <sys/sysmacros.h>
#endif
#ifndef major
#include <sys/types.h>
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment