1
-
2
- SUMMARY = "Libdispatch "
3
- HOMEPAGE = "https://github.com/apple /swift-corelibs-libdispatch"
1
+ SUMMARY = "libdispatch"
2
+ DESCRIPTION = "The libdispatch Project, (a.k.a. Grand Central Dispatch), for concurrency on multicore hardware "
3
+ HOMEPAGE = "https://github.com/swiftlang /swift-corelibs-libdispatch"
4
4
5
5
LICENSE = "Apache-2.0"
6
6
LIC_FILES_CHKSUM = "file://${S} /LICENSE;md5=1cd73afe3fb82e8d5c899b9d926451d0"
7
7
8
8
require swift -version . inc
9
- PV = "${SWIFT_VERSION} "
9
+ PV = "${SWIFT_VERSION} +git ${SRCPV} "
10
10
11
- SRC_URI = "git://github.com/apple/ swift-corelibs-libdispatch.git;protocol=https;tag=swift- ${PV} -RELEASE;nobranch=1 "
11
+ DEPENDS = "swift-stdlib "
12
12
13
- DEPENDS = "swift-stdlib ncurses "
13
+ SRC_URI = "git://github.com/swiftlang/ swift-corelibs-libdispatch.git;protocol=https;tag=swift- ${SWIFT_VERSION} -RELEASE;nobranch=1 "
14
14
15
15
S = "${WORKDIR} /git"
16
+ LIBDISPATCH_BUILDDIR = "${WORKDIR} /build"
16
17
17
18
inherit swift -cmake -base
18
19
@@ -22,15 +23,45 @@ TARGET_LDFLAGS += "-L${STAGING_DIR_TARGET}/usr/lib/swift/linux"
22
23
EXTRA_OECMAKE += "-DENABLE_SWIFT=YES"
23
24
24
25
# Ensure the right CPU is targeted
25
- cmake_do_generate_toolchain_file_append () {
26
+ cmake_do_generate_toolchain_file : append () {
26
27
sed -i 's/set([ ]*CMAKE_SYSTEM_PROCESSOR .*[ ]*)/set(CMAKE_SYSTEM_PROCESSOR ${TARGET_CPU_NAME} )/' ${WORKDIR} /toolchain . cmake
27
28
}
28
29
29
- do_install_append () {
30
- # Copy cmake build modules
31
- mkdir -p ${D}${libdir} /swift /dispatch /cmake
32
- cp -rf ${WORKDIR} /build /cmake /modules /* ${D}${libdir} /swift /dispatch /cmake /
30
+ do_install :append () {
31
+ # move the header files out of /usr/lib/swift and into /usr/include,
32
+ # because we want Swift C shims to be able to pick them up without fancy
33
+ # SwiftPM magic
34
+ install -d ${D}${includedir}
35
+ (cd ${D}${libdir} /swift ; mv Block os dispatch ${D}${includedir} )
36
+
37
+ # don't install CMake modules as they have absolute paths in them
38
+ # install -d ${D}${libdir}/cmake/dispatch
39
+ # install -m 0644 ${LIBDISPATCH_BUILDDIR}/cmake/modules/dispatchConfig.cmake ${D}${libdir}/cmake/dispatch/
40
+ # install -m 0644 ${LIBDISPATCH_BUILDDIR}/cmake/modules/dispatchExports.cmake ${D}${libdir}/cmake/dispatch/
33
41
}
34
42
35
- FILES_${PN} = "${libdir} /swift/*"
36
- INSANE_SKIP_${PN} = "file-rdeps"
43
+ FILES :${PN} = "\
44
+ ${libdir} /swift/linux/libdispatch.so \
45
+ ${libdir} /swift/linux/libswiftDispatch.so \
46
+ ${libdir} /swift/linux/libBlocksRuntime.so \
47
+ "
48
+
49
+ FILES :${PN} -dev = "\
50
+ ${libdir} /swift/linux/${SWIFT_TARGET_ARCH} /Dispatch.swiftdoc \
51
+ ${libdir} /swift/linux/${SWIFT_TARGET_ARCH} /Dispatch.swiftmodule \
52
+ ${includedir} /Block \
53
+ ${includedir} /os \
54
+ ${includedir} /dispatch \
55
+ "
56
+
57
+ FILES :${PN} -staticdev = "\
58
+ ${libdir} /swift_static/linux/libdispatch.a \
59
+ ${libdir} /swift_static/linux/libswiftDispatch.a \
60
+ ${libdir} /swift_static/linux/libBlocksRuntime.a \
61
+ ${libdir} /swift_static/linux/libDispatchStubs.a \
62
+ ${libdir} /swift_static/linux/${SWIFT_TARGET_ARCH} /Dispatch.swiftdoc \
63
+ ${libdir} /swift_static/linux/${SWIFT_TARGET_ARCH} /Dispatch.swiftmodule \
64
+ ${libdir} /swift_static/linux/dispatch \
65
+ "
66
+
67
+ INSANE_SKIP :${PN} = "file-rdeps"
0 commit comments