diff options
Diffstat (limited to 'meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb')
-rw-r--r-- | meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb index 49c3fe827a..64fea8ed95 100644 --- a/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb +++ b/meta-selftest/recipes-test/selftest-hardlink/selftest-hardlink.bb | |||
@@ -6,10 +6,14 @@ SRC_URI = "file://hello.c \ | |||
6 | file://gdb.sh \ | 6 | file://gdb.sh \ |
7 | " | 7 | " |
8 | 8 | ||
9 | S = "${WORKDIR}" | 9 | S = "${WORKDIR}/sources" |
10 | UNPACKDIR = "${S}" | ||
10 | 11 | ||
11 | do_compile () { | 12 | do_compile () { |
12 | ${CC} hello.c -o hello1 ${CFLAGS} ${LDFLAGS} | 13 | ${CC} hello.c -o hello1 ${CFLAGS} ${LDFLAGS} |
14 | |||
15 | ${CC} hello.c -c -o hello.o ${CFLAGS} | ||
16 | ${AR} rcs libhello.a hello.o | ||
13 | } | 17 | } |
14 | 18 | ||
15 | do_install () { | 19 | do_install () { |
@@ -22,9 +26,19 @@ do_install () { | |||
22 | ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello3 | 26 | ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello3 |
23 | ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello4 | 27 | ln ${D}${bindir}/hello1 ${D}${libexecdir}/hello4 |
24 | 28 | ||
29 | # We need so many hardlink copies to look for specific race conditions | ||
30 | install -d ${D}${libdir} | ||
31 | install -m 0644 libhello.a ${D}${libdir} | ||
32 | for num in `seq 1 100` ; do | ||
33 | ln ${D}${libdir}/libhello.a ${D}${libdir}/libhello-${num}.a | ||
34 | done | ||
35 | |||
25 | dd if=/dev/zero of=${D}${bindir}/sparsetest bs=1 count=0 seek=1M | 36 | dd if=/dev/zero of=${D}${bindir}/sparsetest bs=1 count=0 seek=1M |
26 | } | 37 | } |
27 | 38 | ||
28 | RDEPENDS:${PN}-gdb += "gdb" | 39 | RDEPENDS:${PN}-gdb += "gdb" |
29 | PACKAGES =+ "${PN}-gdb" | 40 | PACKAGES =+ "${PN}-gdb" |
30 | FILES:${PN}-gdb = "${bindir}/gdb.sh" | 41 | FILES:${PN}-gdb = "${bindir}/gdb.sh" |
42 | |||
43 | PACKAGE_STRIP_STATIC = "1" | ||
44 | PACKAGE_DEBUG_STATIC_SPLIT = "1" | ||