Browse Source

Fix detection whether the system is big endian

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/2/head
Slávek Banko 2 years ago
parent
commit
81ed8f2068
2 changed files with 33 additions and 0 deletions
  1. 22
    0
      ConfigureChecks.cmake
  2. 11
    0
      config.h.cmake

+ 22
- 0
ConfigureChecks.cmake View File

@@ -14,6 +14,10 @@
14 14
 
15 15
 # required stuff
16 16
 tde_setup_architecture_flags( )
17
+
18
+include(TestBigEndian)
19
+test_big_endian(WORDS_BIGENDIAN)
20
+
17 21
 find_package( TQt )
18 22
 find_package( TDE )
19 23
 
@@ -31,18 +35,36 @@ if( NOT HAVE_LIBDL )
31 35
 endif( NOT HAVE_LIBDL )
32 36
 
33 37
 
38
+# stdint.h (drkonqi)
39
+if( BUILD_DRKONQI )
40
+  check_include_file( stdint.h HAVE_STDINT_H )
41
+endif( )
42
+
43
+
34 44
 # termios.h (tdm, tdeioslave)
35 45
 if( BUILD_TDM OR BUILD_TDEIOSLAVES )
36 46
   check_include_file( termios.h HAVE_TERMIOS_H )
37 47
 endif( )
38 48
 
39 49
 
50
+# sys/bitypes.h (drkonqi)
51
+if( BUILD_DRKONQI )
52
+  check_include_file( sys/bitypes.h HAVE_SYS_BITYPES_H )
53
+endif( )
54
+
55
+
40 56
 # sys/ioctl.h (tdeioslave/fish, kcontrol/info)
41 57
 if( BUILD_TDEIOSLAVES OR BUILD_KCONTROL )
42 58
   check_include_file( sys/ioctl.h HAVE_SYS_IOCTL_H )
43 59
 endif( )
44 60
 
45 61
 
62
+# sys/types.h (drkonqi, tdeioslave/smtp)
63
+if( BUILD_DRKONQI OR BUILD_TDEIOSLAVES )
64
+  check_include_file( sys/types.h HAVE_SYS_TYPES_H )
65
+endif( )
66
+
67
+
46 68
 # pam
47 69
 if( WITH_PAM AND (BUILD_KCHECKPASS OR BUILD_TDM) )
48 70
   check_library_exists( pam pam_start "" HAVE_PAM )

+ 11
- 0
config.h.cmake View File

@@ -3,6 +3,10 @@
3 3
 // Defined if you have fvisibility and fvisibility-inlines-hidden support.
4 4
 #cmakedefine __KDE_HAVE_GCC_VISIBILITY 1
5 5
 
6
+/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
7
+   significant byte first (like Motorola and SPARC, unlike Intel). */
8
+#cmakedefine WORDS_BIGENDIAN @WORDS_BIGENDIAN@
9
+
6 10
 // Defined if compiler supports long long type.
7 11
 #cmakedefine HAVE_LONG_LONG 1
8 12
 
@@ -46,6 +50,13 @@
46 50
 // tdm, tdeioslave
47 51
 #cmakedefine HAVE_TERMIOS_H 1
48 52
 
53
+// drkonqi
54
+#cmakedefine HAVE_STDINT_H 1
55
+#cmakedefine HAVE_SYS_BITYPES_H
56
+
57
+// drkonqi, tdeioslave
58
+#cmakedefine HAVE_SYS_TYPES_H 1
59
+
49 60
 // tdeioslave/media
50 61
 #cmakedefine WITH_HAL 1
51 62
 #ifdef WITH_HAL

Loading…
Cancel
Save