File: CheckTarget.m4

package info (click to toggle)
libbson 1.4.2-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 19,504 kB
  • ctags: 2,615
  • sloc: ansic: 21,684; makefile: 430; python: 278; sh: 42
file content (29 lines) | stat: -rw-r--r-- 615 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
AC_CANONICAL_SYSTEM

enable_crosscompile=no
if test "x$host" != "x$target"; then
    enable_crosscompile=yes
    case "$target" in
        *-mingw*|*-*-cygwin*)
            TARGET_OS=windows
            ;;
        arm*-darwin*)
            TARGET_OS=unix
            ;;
        powerpc64-*-linux-gnu)
            TARGET_OS=unix
            ;;
        arm*-linux-*)
            TARGET_OS=unix
            ;;
        *)
            AC_MSG_ERROR([Cross compiling is not supported for target $target])
            ;;
    esac
fi


AC_SUBST(BSON_OS, 1)
if test "$TARGET_OS" = "windows"; then
    AC_SUBST(BSON_OS, 2)
fi