diff options
author | Alexey Neyman <stilor@att.net> | 2017-07-02 13:12:53 -0700 |
---|---|---|
committer | Alexey Neyman <stilor@att.net> | 2017-07-08 10:57:56 -0700 |
commit | f63fbd356f4e80b2f597796039eb79a69121fb4d (patch) | |
tree | 28d8f105c0e00fd6697b48790c7f3f3ffa515436 /maintainer | |
parent | d0ff020e23372a8eccd319c142c72d266c652f56 (diff) | |
download | crosstool-ng-f63fbd356f4e80b2f597796039eb79a69121fb4d.tar.gz crosstool-ng-f63fbd356f4e80b2f597796039eb79a69121fb4d.tar.bz2 crosstool-ng-f63fbd356f4e80b2f597796039eb79a69121fb4d.zip |
Allow for custom archive names
... and directories therein.
Signed-off-by: Alexey Neyman <stilor@att.net>
Diffstat (limited to 'maintainer')
-rwxr-xr-x | maintainer/gen-versions.sh | 11 | ||||
-rw-r--r-- | maintainer/kconfig-versions.template | 8 |
2 files changed, 14 insertions, 5 deletions
diff --git a/maintainer/gen-versions.sh b/maintainer/gen-versions.sh index 8144b62c..09ebc0b7 100755 --- a/maintainer/gen-versions.sh +++ b/maintainer/gen-versions.sh @@ -132,7 +132,7 @@ run_lines() { local start="${1}" local end="${2}" - local l lnext s v + local l lnext s s1 v debug "Running lines ${start}..${end}" l=${start} @@ -142,6 +142,7 @@ run_lines() # Expand @@foo@@ to ${info[foo]}. First escape variables/backslashes for evals below. s="${s//\\/\\\\}" s="${s//\$/\\\$}" + s1= while [ -n "${s}" ]; do case "${s}" in *@@*@@*) @@ -150,16 +151,19 @@ run_lines() if [ "${info[${v}]+set}" != "set" ]; then error "line ${l}: reference to undefined variable '${v}'" fi - s="${s%%@@*}\${info[${v}]}${s#*@@*@@}" + s1="${s1}${s%%@@*}\${info[${v}]}" + s="${s#*@@*@@}" ;; *@@*) error "line ${l}: non-paired @@ markers" ;; *) + s1="${s1}${s}" break ;; esac done + s=${s1} debug "Evaluate: ${s}" case "${s}" in @@ -448,7 +452,8 @@ enter_fork() info[fork]=${fork} info[name]=${fork} info[mirrors]= - info[archivesuffix]= + info[archive_filename]='@{pkg_name}-@{version}' + info[archive_dirname]='@{pkg_name}-@{version}' eval `read_package_desc ${fork}` diff --git a/maintainer/kconfig-versions.template b/maintainer/kconfig-versions.template index c7ab461f..af78f3cb 100644 --- a/maintainer/kconfig-versions.template +++ b/maintainer/kconfig-versions.template @@ -172,9 +172,13 @@ config @@pfx@@_MIRRORS string default "@@mirrors@@" -config @@pfx@@_ARCHIVE_SUFFIX +config @@pfx@@_ARCHIVE_FILENAME string - default "@@archivesuffix@@" + default "@@archive_filename@@" + +config @@pfx@@_ARCHIVE_DIRNAME + string + default "@@archive_dirname@@" #!end-if |