summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@chromium.org>2018-09-17 23:40:54 -0400
committerMike Frysinger <vapier@gentoo.org>2018-09-17 23:48:36 -0400
commitc467a8a6e70b793221cd1f6a6658894c2e4a190e (patch)
tree210d922f3f92649c4f0209397c3e786dbbcab364 /sys-devel/bc/files/bc-1.07.1-no-ed-its-sed.patch
parentmail-filter/spamassassin: new version 3.4.2. (diff)
downloadgentoo-c467a8a6e70b793221cd1f6a6658894c2e4a190e.tar.gz
gentoo-c467a8a6e70b793221cd1f6a6658894c2e4a190e.tar.bz2
gentoo-c467a8a6e70b793221cd1f6a6658894c2e4a190e.zip
sys-devel/bc: replace ed usage with sed
The ed usage here is minor and easy enough to convert to sed. This avoids a depend that no one else generally has.
Diffstat (limited to 'sys-devel/bc/files/bc-1.07.1-no-ed-its-sed.patch')
-rw-r--r--sys-devel/bc/files/bc-1.07.1-no-ed-its-sed.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/sys-devel/bc/files/bc-1.07.1-no-ed-its-sed.patch b/sys-devel/bc/files/bc-1.07.1-no-ed-its-sed.patch
new file mode 100644
index 000000000000..ce8e456186b7
--- /dev/null
+++ b/sys-devel/bc/files/bc-1.07.1-no-ed-its-sed.patch
@@ -0,0 +1,23 @@
+in Gentoo, everyone has sed. no one really has ed. tweak this minor script
+to use sed instead of ed. the changes are straight forward:
+* change \$ to $
+* merge last two $,$ commands into one
+* delete w/q commands
+
+--- a/bc/fix-libmath_h
++++ b/bc/fix-libmath_h
+@@ -1,9 +1,6 @@
+-ed libmath.h <<EOS-EOS
++sed -i libmath.h -e '
+ 1,1s/^/{"/
+-1,\$s/\$/",/
+-2,\$s/^/"/
+-\$,\$d
+-\$,\$s/,\$/,0}/
+-w
+-q
+-EOS-EOS
++1,$s/$/",/
++2,$s/^/"/
++$s/.*/0}/
++'