summaryrefslogtreecommitdiff
path: root/maketgz
diff options
context:
space:
mode:
authorMamta Upadhyay <upadhyaym@vmware.com>2018-06-14 09:29:43 -0700
committerDaniel Stenberg <daniel@haxx.se>2018-06-14 23:17:38 +0200
commitcf448436facd28da1bafe031d14a8bc4f165ddaa (patch)
tree8feddb038a5f5c9bdad59507f29e8413fecc1aa8 /maketgz
parent351dabbf3dfe1370045a29aa6dba3e0a3686eaeb (diff)
downloadcurl-cf448436facd28da1bafe031d14a8bc4f165ddaa.tar.gz
maketgz: fix sed issues on OSX
maketgz creates release tarballs and removes the -DEV string in curl version (e.g. 7.58.0-DEV), else -DEV shows up on command line when curl is run. maketgz works fine on linux but fails on OSX. Problem is with the sed commands that use option -i without an extension. Maketgz expects GNU sed instead of BSD and this simply won't work on OSX. Adding a backup extension .bak after -i fixes this issue Running the script as if on OSX gives this error: sed: -e: No such file or directory Adding a .bak extension resolves it Closes #2660
Diffstat (limited to 'maketgz')
-rwxr-xr-xmaketgz6
1 files changed, 3 insertions, 3 deletions
diff --git a/maketgz b/maketgz
index b740173db..8fe8d8e92 100755
--- a/maketgz
+++ b/maketgz
@@ -78,7 +78,7 @@ fi
datestamp=`date +"%F"`
# Replace version number in header file:
-sed -i -e 's/^#define LIBCURL_VERSION .*/#define LIBCURL_VERSION "'$libversion'"/g' \
+sed -i.bak -e 's/^#define LIBCURL_VERSION .*/#define LIBCURL_VERSION "'$libversion'"/g' \
-e 's/^#define LIBCURL_VERSION_NUM .*/#define LIBCURL_VERSION_NUM 0x'$numeric'/g' \
-e 's/^#define LIBCURL_VERSION_MAJOR .*/#define LIBCURL_VERSION_MAJOR '$major'/g' \
-e 's/^#define LIBCURL_VERSION_MINOR .*/#define LIBCURL_VERSION_MINOR '$minor'/g' \
@@ -87,10 +87,10 @@ sed -i -e 's/^#define LIBCURL_VERSION .*/#define LIBCURL_VERSION "'$libversion'"
$HEADER
# Replace version number in header file:
-sed -i 's/#define CURL_VERSION .*/#define CURL_VERSION "'$curlversion'"/g' $CHEADER
+sed -i.bak 's/#define CURL_VERSION .*/#define CURL_VERSION "'$curlversion'"/g' $CHEADER
# Replace version number in plist file:
-sed -i "s/7\.12\.3/$libversion/g" $PLIST
+sed -i.bak "s/7\.12\.3/$libversion/g" $PLIST
if test -n "$only"; then
# done!