Commit 83424a7b authored by mara's avatar mara

fix sed get head and footer in original slackbuild scripts

parent 15564ab8
......@@ -43,7 +43,7 @@ fix_default() {
for pf in $(find ${_WORK_DIR}/ -maxdepth 1 -type f | grep .SlackBuild);do
pf=$(basename "$pf")
echo "$pf"
sed -n '/if \[ \"$ARCH\" = \"\(i.86\)\" \]/{:a;N;/fi$/!ba;N;s/.*\n/case \"\$ARCH\" in\
sed -n '/^if \[ \"$ARCH\" = \"\(i.86\)\" \]/{:a;N;/^fi$/!ba;N;s/.*\n/case \"\$ARCH\" in\
i?86\) SLKCFLAGS=\"-O2 -march=i586 -mtune=i686\"\
LIBDIRSUFFIX=\"\"\
;;\
......@@ -71,7 +71,7 @@ fix_global() {
patching_files() {
local PATCH_FILES=$(find -maxdepth 1 -type f | grep patch$ | sed 's#.patch##')
local count=1
for pf in "${PATCH_FILES}";do
for pf in ${PATCH_FILES};do
pf=$(basename "$pf")
[[ -z "$pf" ]] && continue
pushd ${_WORK_DIR} 2>&1>/dev/null
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment