~ubuntu-branches/ubuntu/trusty/expat/trusty-proposed

« back to all changes in this revision

Viewing changes to ConfigureChecks.cmake

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2012-03-20 22:37:22 UTC
  • mfrom: (1.1.4) (5.1.7 precise)
  • Revision ID: package-import@ubuntu.com-20120320223722-wq8sq4gykhlvc8j9
Tags: 2.1.0~beta3-1
* QA upload.
* Beta release 2.1.0 beta3. Closes: #663579.
  - CVE-2012-1147 - Resource leak in readfilemap.c.
  - CVE-2012-1148 - Memory leak in poolGrow.
  - CVE-2012-0876 - Hash DOS attack.
  - Remove patches applied upstream.
* Remove Daniel from uploaders (orphaned package).
* Update package format to 3.0.
* Enable hardened build. Closes: #653526.
* Add a symbols file.
* Install expat pkgconfig file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
include(CheckIncludeFile)
 
2
include(CheckIncludeFiles)
 
3
include(CheckFunctionExists)
 
4
include(CheckSymbolExists)
 
5
include(TestBigEndian)
 
6
 
 
7
check_include_file("dlfcn.h" HAVE_DLFCN_H)
 
8
check_include_file("fcntl.h" HAVE_FCNTL_H)
 
9
check_include_file("inttypes.h" HAVE_INTTYPES_H)
 
10
check_include_file("memory.h" HAVE_MEMORY_H)
 
11
check_include_file("stdint.h" HAVE_STDINT_H)
 
12
check_include_file("stdlib.h" HAVE_STDLIB_H)
 
13
check_include_file("strings.h" HAVE_STRINGS_H)
 
14
check_include_file("string.h" HAVE_STRING_H)
 
15
check_include_file("sys/stat.h" HAVE_SYS_STAT_H)
 
16
check_include_file("sys/types.h" HAVE_SYS_TYPES_H)
 
17
check_include_file("unistd.h" HAVE_UNISTD_H)
 
18
 
 
19
check_function_exists("getpagesize" HAVE_GETPAGESIZE)
 
20
check_function_exists("bcopy" HAVE_BCOPY)
 
21
check_symbol_exists("memmove" "string.h" HAVE_MEMMOVE)
 
22
check_function_exists("mmap" HAVE_MMAP)
 
23
 
 
24
#/* Define to 1 if you have the ANSI C header files. */
 
25
check_include_files("stdlib.h;stdarg.h;string.h;float.h" STDC_HEADERS)
 
26
 
 
27
test_big_endian(WORDS_BIGENDIAN)
 
28
#/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */
 
29
if(WORDS_BIGENDIAN)
 
30
    set(BYTEORDER 4321)
 
31
else(WORDS_BIGENDIAN)
 
32
    set(BYTEORDER 1234)
 
33
endif(WORDS_BIGENDIAN)
 
34
 
 
35
if(HAVE_SYS_TYPES_H)
 
36
    check_symbol_exists("off_t" "sys/types.h" OFF_T)
 
37
    check_symbol_exists("size_t" "sys/types.h" SIZE_T)
 
38
else(HAVE_SYS_TYPES_H)
 
39
    set(OFF_T "long")
 
40
    set(SIZE_T "unsigned")
 
41
endif(HAVE_SYS_TYPES_H)
 
42
 
 
43
configure_file(expat_config.h.cmake expat_config.h)
 
44
add_definitions(-DHAVE_EXPAT_CONFIG_H)