summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorYann E. MORIN" <yann.morin.1998@anciens.enib.fr>2010-07-02 22:17:54 (GMT)
committerYann E. MORIN" <yann.morin.1998@anciens.enib.fr>2010-07-02 22:17:54 (GMT)
commit974f60e98adf71555f685fa69ee649fe28d72d31 (patch)
tree48b2d9c30d3e2db3d1925c334bd6f11290a07bce /scripts
parent3fafacd093dc78a5c328d86e719c388b7e5a062a (diff)
libc/uClibc: fix snapshots
Snapshots are in a subdir named uClibc, not uClibc-snapshot (or uClibc-YYYYMMDD either).
Diffstat (limited to 'scripts')
-rw-r--r--scripts/build/libc/uClibc.sh23
1 files changed, 19 insertions, 4 deletions
diff --git a/scripts/build/libc/uClibc.sh b/scripts/build/libc/uClibc.sh
index e10f3ec..ba5dbf1 100644
--- a/scripts/build/libc/uClibc.sh
+++ b/scripts/build/libc/uClibc.sh
@@ -19,14 +19,29 @@ do_libc_get() {
return 0
}
+libc_uclibc_src_dir() {
+ if [ -z "${CT_LIBC_V_snapshot}" \
+ -a -z "${CT_LIBC_V_specific_date}" \
+ ]; then
+ echo "${CT_SRC_DIR}/uClibc-${CT_LIBC_VERSION}"
+ else
+ echo "${CT_SRC_DIR}/uClibc"
+ fi
+}
+
# Extract uClibc
do_libc_extract() {
CT_Extract "uClibc-${CT_LIBC_VERSION}"
- CT_Patch "uClibc" "${CT_LIBC_VERSION}"
+ # Don't patch snapshots
+ if [ -z "${CT_LIBC_V_snapshot}" \
+ -a -z "${CT_LIBC_V_specific_date}" \
+ ]; then
+ CT_Patch "uClibc" "${CT_LIBC_VERSION}"
+ fi
# uClibc locales
if [ "${CT_LIBC_UCLIBC_LOCALES}" = "y" ]; then
- CT_Pushd "${CT_SRC_DIR}/uClibc-${CT_LIBC_VERSION}/extra/locale"
+ CT_Pushd "$(libc_uclibc_src_dir)/extra/locale"
CT_Extract nochdir "uClibc-locale-030818"
CT_Patch nochdir "uClibc" "locale-030818"
CT_Popd
@@ -60,7 +75,7 @@ do_libc_headers() {
# Simply copy files until uClibc has the ability to build out-of-tree
CT_DoLog EXTRA "Copying sources to build dir"
- CT_DoExecLog ALL cp -av "${CT_SRC_DIR}/uClibc-${CT_LIBC_VERSION}" \
+ CT_DoExecLog ALL cp -av "$(libc_uclibc_src_dir)" \
"${CT_BUILD_DIR}/build-libc-headers"
cd "${CT_BUILD_DIR}/build-libc-headers"
@@ -100,7 +115,7 @@ do_libc() {
# Simply copy files until uClibc has the ability to build out-of-tree
CT_DoLog EXTRA "Copying sources to build dir"
- CT_DoExecLog ALL cp -av "${CT_SRC_DIR}/uClibc-${CT_LIBC_VERSION}" \
+ CT_DoExecLog ALL cp -av "$(libc_uclibc_src_dir)" \
"${CT_BUILD_DIR}/build-libc"
cd "${CT_BUILD_DIR}/build-libc"