Skip to content

Commit a9e3885

Browse files
authored
Merge pull request #286 from compnerd/major-update
linux: update header used for `major` macro
2 parents 80dd736 + 1860362 commit a9e3885

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ check_include_files("sys/cdefs.h" HAVE_SYS_CDEFS_H)
160160
check_include_files("sys/guarded.h" HAVE_SYS_GUARDED_H)
161161
check_include_files("sys/stat.h" HAVE_SYS_STAT_H)
162162
check_include_files("sys/types.h" HAVE_SYS_TYPES_H)
163+
check_include_files("sys/sysmacros.h" HAVE_SYS_SYSMACROS_H)
163164
check_include_files("unistd.h" HAVE_UNISTD_H)
164165
check_include_files("objc/objc-internal.h" HAVE_OBJC)
165166

cmake/config.h.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,9 @@
188188
/* Define to 1 if you have the <sys/types.h> header file. */
189189
#cmakedefine01 HAVE_SYS_TYPES_H
190190

191+
/* Define to 1 if you have the <sys/sysmacros.h> header file. */
192+
#cmakedefine01 HAVE_SYS_SYSMACROS_H
193+
191194
/* Define to 1 if you have the <TargetConditionals.h> header file. */
192195
#cmakedefine HAVE_TARGETCONDITIONALS_H
193196

os/linux_base.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
#ifndef __OS_LINUX_BASE__
1414
#define __OS_LINUX_BASE__
1515

16+
#include <config/config_ac.h>
17+
18+
#if HAVE_SYS_SYSMACROS_H
19+
#include <sys/sysmacros.h>
20+
#endif
1621
#include <sys/param.h>
1722

1823
#if HAVE_SYS_CDEFS_H

0 commit comments

Comments
 (0)