diff options
author | Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> | 2009-03-03 21:53:50 +0000 |
---|---|---|
committer | Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> | 2009-03-03 21:53:50 +0000 |
commit | 46d3ec734ad68cfa71eb8aa1a93f832ce0264bf6 (patch) | |
tree | cb118388af8bb3e3b293249cb9d23bec799f7d41 /scripts | |
parent | b6b7925fcb3093e8d9fabed7d2d61ad1b4312daf (diff) | |
download | crosstool-ng-46d3ec734ad68cfa71eb8aa1a93f832ce0264bf6.tar.gz crosstool-ng-46d3ec734ad68cfa71eb8aa1a93f832ce0264bf6.tar.bz2 crosstool-ng-46d3ec734ad68cfa71eb8aa1a93f832ce0264bf6.zip |
Warn the user when he/she tries to save a sample that uses local patches
and/or custom Linux kernel headers.
/trunk/scripts/saveSample.sh.in | 18 17 1 0 +++++++++++++++++-
1 file changed, 17 insertions(+), 1 deletion(-)
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/saveSample.sh.in | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/scripts/saveSample.sh.in b/scripts/saveSample.sh.in index fe563115..b9bced49 100755 --- a/scripts/saveSample.sh.in +++ b/scripts/saveSample.sh.in @@ -24,6 +24,22 @@ rm -f "${tmp_log_file}" CT_TestOrAbort "Configuration file not found. Please create one." -f .config . .config +# We can not reliably save a sample which either uses local patches +# and/or custom Linux kernel headers. Warn the user about this issue +# and continue if he/she confirms sving the sample. +if [ "${CT_CUSTOM_PATCH}" = "y" ]; then + exec >&7 + echo "You are using local patches." + echo "You will not be able to (easily) share this sample in this case." + read -p "Press Ctrl-C to stop now, or Enter to continue..." +fi +if [ "${CT_KERNEL_LINUX_USE_CUSTOM_HEADERS}" = "y" ]; then + exec >&7 + echo "You are using custom Linux headers." + echo "You will not be able to (easily) share this sample in this case." + read -p "Press Ctrl-C to stop now, or Enter to continue..." +fi + # Do not use a progress bar unset CT_LOG_PROGRESS_BAR @@ -79,7 +95,7 @@ fi if [ -n "${CT_LIBC_UCLIBC_CONFIG_FILE}" ]; then # We save the file, and then point the saved sample to this file CT_DoAddFileToSample "${CT_LIBC_UCLIBC_CONFIG_FILE}" "samples/${CT_TARGET}/${CT_LIBC}-${CT_LIBC_VERSION}.config" - "${sed}" -r -i -e 's|^(CT_LIBC_UCLIBC_CONFIG_FILE=).+$|\1"'"${samp_top_dir}"'/samples/${CT_TARGET}/${CT_LIBC}-${CT_LIBC_VERSION}.config"|;' \ + "${sed}" -r -i -e 's|^(CT_LIBC_UCLIBC_CONFIG_FILE)=.+$|\1="'"${samp_top_dir}"'/samples/${CT_TARGET}/${CT_LIBC}-${CT_LIBC_VERSION}.config"|;' \ "samples/${CT_TARGET}/crosstool.config" else # remove any dangling files |