mirror of
https://github.com/yann64/haikuports.git
synced 2026-05-05 14:38:51 +02:00
hBlock: bump (#8800)
This commit is contained in:
committed by
GitHub
parent
9d36338d7a
commit
6c3112b151
48
net-firewall/hblock/hblock-3.4.2.recipe
Normal file
48
net-firewall/hblock/hblock-3.4.2.recipe
Normal file
@@ -0,0 +1,48 @@
|
||||
SUMMARY="Adblocker that creates a hosts file from multiple sources"
|
||||
DESCRIPTION="hBlock is a POSIX-compliant shell script that gets a list of domains that serve \
|
||||
ads, tracking scripts and malware from multiple sources and creates a hosts \
|
||||
file, among other formats, that prevents your system from connecting to them."
|
||||
HOMEPAGE="https://github.com/hectorm/hblock"
|
||||
COPYRIGHT="2023 Héctor Molinero Fernández"
|
||||
LICENSE="MIT"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/hectorm/hblock/archive/v${portVersion:?}.tar.gz"
|
||||
CHECKSUM_SHA256="4b5ff1ddf543d46610ccfa510689f2c11b32eb7561bf76815da853e6f0dd6bcd"
|
||||
PATCHES="hblock-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
hblock = ${portVersion:?}
|
||||
cmd:hblock
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
cmd:curl
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:install
|
||||
cmd:make
|
||||
cmd:sed
|
||||
"
|
||||
|
||||
PATCH()
|
||||
{
|
||||
# Replace hardcoded paths.
|
||||
bSystemEtcDirectory=$(finddir B_SYSTEM_ETC_DIRECTORY)
|
||||
bSystemSettingsDirectory=$(finddir B_SYSTEM_SETTINGS_DIRECTORY)
|
||||
sed -i \
|
||||
-e "s|\"\${ETCDIR?}/hosts\"|\"${bSystemSettingsDirectory:?}/network/hosts\"|" \
|
||||
-e "s|'/etc'|'${bSystemEtcDirectory:?}'|" \
|
||||
./hblock
|
||||
sed -i \
|
||||
-e "s|,/etc/hosts|,${bSystemSettingsDirectory:?}/network/hosts|" \
|
||||
-e "s|,/etc/|,${bSystemEtcDirectory:?}/|" \
|
||||
./hblock.1
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install prefix="${prefix:?}" bindir="${binDir:?}" mandir="${manDir:?}"
|
||||
}
|
||||
Reference in New Issue
Block a user