logo

overlay

My own overlay for experimentations, use with caution, no support is provided git clone https://hacktivis.me/git/overlay.git

searx-0.15.0.ebuild (1476B)


  1. # Copyright 2019 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=7
  4. PYTHON_COMPAT=( python2_6 python3_{4,5,6} )
  5. inherit savedconfig distutils-r1
  6. DESCRIPTION="Decentralized and privacy-respecting, hackable metasearch engine"
  7. HOMEPAGE="https://github.com/asciimoo/searx https://searx.me"
  8. SRC_URI="https://github.com/asciimoo/searx/archive/v${PV}.tar.gz -> ${P}.tar.gz"
  9. LICENSE="AGPL-3"
  10. SLOT="0"
  11. KEYWORDS="~amd64"
  12. DEPEND="
  13. >=dev-python/certifi-2017.11.5[${PYTHON_USEDEP}]
  14. >=dev-python/flask-1.0.2[${PYTHON_USEDEP}]
  15. >=dev-python/flask-babel-0.11.2[${PYTHON_USEDEP}]
  16. >=dev-python/lxml-4.2.3[${PYTHON_USEDEP}]
  17. >=dev-python/idna-2.7[${PYTHON_USEDEP}]
  18. >=dev-python/pygments-2.1.3[${PYTHON_USEDEP}]
  19. >=dev-python/pyopenssl-18.0.0[${PYTHON_USEDEP}]
  20. >=dev-python/python-dateutil-2.7.3[${PYTHON_USEDEP}]
  21. >=dev-python/pyyaml-3.13[${PYTHON_USEDEP}]
  22. >=dev-python/requests-2.19.1[socks5,${PYTHON_USEDEP}]
  23. ${PYTHON_DEPS}
  24. "
  25. RDEPEND="${DEPEND}"
  26. src_prepare() {
  27. local mysecretkey="$(python -c 'import random; print("%x" % random.getrandbits(16*8))')"
  28. sed -i "s/ultrasecretkey/${mysecretkey}/g" searx/settings.yml || die "setting the secret key"
  29. restore_config searx/settings.yml
  30. sed -i "s;'tests/.*',$;;" setup.py || die "removing installation of tests"
  31. rm -r tests || die "removal of tests"
  32. distutils-r1_src_prepare
  33. }
  34. src_install() {
  35. distutils-r1_src_install
  36. save_config searx/settings.yml
  37. }