diff options
author | Alois Klink <alois@aloisklink.com> | 2022-11-23 23:32:14 +0000 |
---|---|---|
committer | Josef Schlehofer <pepe.schlehofer@gmail.com> | 2022-12-08 10:54:55 +0100 |
commit | 6703d7623097b591ea08c12e66351eed884e1005 (patch) | |
tree | 9ee491224fff4ee4ad587c39aee6dfb89bff0629 /net/privoxy/Makefile | |
parent | d20f2e324d65e34cc4307d03099e8e8b47a8d91e (diff) |
privoxy: fix preinst/postinst script indentation
Fix the indentation of the preinst/postinst scripts for the privoxy
package.
Because these scripts didn't start with `#!/bin/sh`
(they instead started with the TAB character), `/bin/sh` was not used
to start them.
On x86_64 and i386_pentium-mmx, this seems to be fine, but on
arm_cortex-a15_neon-vfpv4 and aarch64_cortex-a53, running these
scripts fails with a:
```
Installing privoxy (3.0.33-3) to root...
Collected errors:
* pkg_run_script: package "privoxy" preinst script returned status 1.
* preinst_configure: Aborting installation of privoxy.
* opkg_install_cmd: Cannot install package privoxy.
```
Reported-by: Marius Dinu <m95d+git@psihoexpert.ro>
Signed-off-by: Alois Klink <alois@aloisklink.com>
Diffstat (limited to 'net/privoxy/Makefile')
-rw-r--r-- | net/privoxy/Makefile | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/net/privoxy/Makefile b/net/privoxy/Makefile index 9f859c4eb..a7f5227b8 100644 --- a/net/privoxy/Makefile +++ b/net/privoxy/Makefile @@ -118,13 +118,13 @@ define Package/privoxy/conffiles endef define Package/privoxy/preinst - #!/bin/sh - [ -n "$${IPKG_INSTROOT}" ] && exit 0 # if run within buildroot exit +#!/bin/sh +[ -n "$${IPKG_INSTROOT}" ] && exit 0 # if run within buildroot exit - # stop service if PKG_UPGRADE - [ "$${PKG_UPGRADE}" = "1" ] && /etc/init.d/privoxy stop >/dev/null 2>&1 - - exit 0 # suppress errors from stop command +# stop service if PKG_UPGRADE +[ "$${PKG_UPGRADE}" = "1" ] && /etc/init.d/privoxy stop >/dev/null 2>&1 + +exit 0 # suppress errors from stop command endef define Package/privoxy/install @@ -156,16 +156,16 @@ define Package/privoxy/install endef define Package/privoxy/postinst - #!/bin/sh - # if exists, update previous version entry missing protocol - (grep -E "privoxy.*8118$$" $${IPKG_INSTROOT}/etc/services) > /dev/null \ - && sed -i "s/privoxy.*8118/privoxy\t\t8118\/tcp/" $${IPKG_INSTROOT}/etc/services - - # add missing tcp and udp entries - (grep -E "privoxy.*8118\/tcp" $${IPKG_INSTROOT}/etc/services) > /dev/null \ - || echo -e "privoxy\t\t8118/tcp" >> $${IPKG_INSTROOT}/etc/services - (grep -E "privoxy.*8118\/udp" $${IPKG_INSTROOT}/etc/services) > /dev/null \ - || echo -e "privoxy\t\t8118/udp" >> $${IPKG_INSTROOT}/etc/services +#!/bin/sh +# if exists, update previous version entry missing protocol +(grep -E "privoxy.*8118$$" $${IPKG_INSTROOT}/etc/services) > /dev/null \ + && sed -i "s/privoxy.*8118/privoxy\t\t8118\/tcp/" $${IPKG_INSTROOT}/etc/services + +# add missing tcp and udp entries +(grep -E "privoxy.*8118\/tcp" $${IPKG_INSTROOT}/etc/services) > /dev/null \ + || echo -e "privoxy\t\t8118/tcp" >> $${IPKG_INSTROOT}/etc/services +(grep -E "privoxy.*8118\/udp" $${IPKG_INSTROOT}/etc/services) > /dev/null \ + || echo -e "privoxy\t\t8118/udp" >> $${IPKG_INSTROOT}/etc/services endef $(eval $(call BuildPackage,privoxy)) |