scripts/build/debug/300-gdb.sh
changeset 3091 41967d32b54e
parent 3072 15fa0b85025e
child 3092 9f6e46b6dc42
     1.1 --- a/scripts/build/debug/300-gdb.sh	Sat Sep 29 14:34:15 2012 +0800
     1.2 +++ b/scripts/build/debug/300-gdb.sh	Thu Oct 11 14:39:42 2012 +1000
     1.3 @@ -48,10 +48,14 @@
     1.4      do_debug_gdb_parts
     1.5  
     1.6      if [ "${do_gdb}" = "y" ]; then
     1.7 -        CT_GetFile "gdb-${CT_GDB_VERSION}"                          \
     1.8 -                   {ftp,http}://ftp.gnu.org/pub/gnu/gdb             \
     1.9 -                   ftp://sources.redhat.com/pub/gdb/{,old-}releases \
    1.10 -                   "${linaro_base_url}/${linaro_series}/${linaro_version}/+download"
    1.11 +        if [ "${CT_GDB_CUSTOM}" = "y" ]; then
    1.12 +            CT_GetCustom "gdb" "${CT_GDB_VERSION}" "${CT_GDB_CUSTOM_LOCATION}"
    1.13 +        else
    1.14 +            CT_GetFile "gdb-${CT_GDB_VERSION}"                          \
    1.15 +                       {ftp,http}://ftp.gnu.org/pub/gnu/gdb             \
    1.16 +                       ftp://sources.redhat.com/pub/gdb/{,old-}releases \
    1.17 +                       "${linaro_base_url}/${linaro_series}/${linaro_version}/+download"
    1.18 +        fi
    1.19      fi
    1.20  
    1.21      if [ "${do_ncurses}" = "y" ]; then
    1.22 @@ -70,6 +74,11 @@
    1.23      do_debug_gdb_parts
    1.24  
    1.25      if [ "${do_gdb}" = "y" ]; then
    1.26 +        # If using custom directory location, nothing to do
    1.27 +        if [    "${CT_GDB_CUSTOM}" = "y" \
    1.28 +             -a -d "${CT_SRC_DIR}/gdb-${CT_GDB_VERSION}" ]; then
    1.29 +            return 0
    1.30 +        fi
    1.31          CT_Extract "gdb-${CT_GDB_VERSION}"
    1.32          CT_Patch "gdb" "${CT_GDB_VERSION}"
    1.33      fi