diff options
Diffstat (limited to 'meta/recipes-devtools/cmake/cmake_3.7.0.bb')
-rw-r--r-- | meta/recipes-devtools/cmake/cmake_3.7.0.bb | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/meta/recipes-devtools/cmake/cmake_3.7.0.bb b/meta/recipes-devtools/cmake/cmake_3.7.0.bb new file mode 100644 index 0000000000..58c6615680 --- /dev/null +++ b/meta/recipes-devtools/cmake/cmake_3.7.0.bb | |||
@@ -0,0 +1,49 @@ | |||
1 | require cmake.inc | ||
2 | |||
3 | inherit cmake | ||
4 | |||
5 | DEPENDS += "curl expat zlib libarchive xz ncurses bzip2" | ||
6 | |||
7 | SRC_URI_append_class-nativesdk = " \ | ||
8 | file://OEToolchainConfig.cmake \ | ||
9 | file://environment.d-cmake.sh" | ||
10 | |||
11 | # Strip ${prefix} from ${docdir}, set result into docdir_stripped | ||
12 | python () { | ||
13 | prefix=d.getVar("prefix", True) | ||
14 | docdir=d.getVar("docdir", True) | ||
15 | |||
16 | if not docdir.startswith(prefix): | ||
17 | bb.fatal('docdir must contain prefix as its prefix') | ||
18 | |||
19 | docdir_stripped = docdir[len(prefix):] | ||
20 | if len(docdir_stripped) > 0 and docdir_stripped[0] == '/': | ||
21 | docdir_stripped = docdir_stripped[1:] | ||
22 | |||
23 | d.setVar("docdir_stripped", docdir_stripped) | ||
24 | } | ||
25 | |||
26 | EXTRA_OECMAKE=" \ | ||
27 | -DCMAKE_DOC_DIR=${docdir_stripped}/cmake-${CMAKE_MAJOR_VERSION} \ | ||
28 | -DCMAKE_USE_SYSTEM_LIBRARIES=1 \ | ||
29 | -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0 \ | ||
30 | -DCMAKE_USE_SYSTEM_LIBRARY_LIBUV=0 \ | ||
31 | -DKWSYS_CHAR_IS_SIGNED=1 \ | ||
32 | -DBUILD_CursesDialog=0 \ | ||
33 | ${@bb.utils.contains('DISTRO_FEATURES', 'largefile', '-DKWSYS_LFS_WORKS=1', '-DKWSYS_LFS_DISABLE=1', d)} \ | ||
34 | " | ||
35 | |||
36 | do_install_append_class-nativesdk() { | ||
37 | mkdir -p ${D}${datadir}/cmake | ||
38 | install -m 644 ${WORKDIR}/OEToolchainConfig.cmake ${D}${datadir}/cmake/ | ||
39 | |||
40 | mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d | ||
41 | install -m 644 ${WORKDIR}/environment.d-cmake.sh ${D}${SDKPATHNATIVE}/environment-setup.d/cmake.sh | ||
42 | } | ||
43 | |||
44 | FILES_${PN}_append_class-nativesdk = " ${SDKPATHNATIVE}" | ||
45 | |||
46 | FILES_${PN} += "${datadir}/cmake-${CMAKE_MAJOR_VERSION}" | ||
47 | FILES_${PN}-doc += "${docdir}/cmake-${CMAKE_MAJOR_VERSION}" | ||
48 | |||
49 | BBCLASSEXTEND = "nativesdk" | ||