1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-18 19:49:40 +00:00

www/web2ldap: update the port to version 1.6.4.

This commit is contained in:
Alexey Dokuchaev 2021-06-08 01:12:36 +00:00
parent dbc1b329a7
commit 7a4d60ba85
4 changed files with 31 additions and 34 deletions

View File

@ -1,7 +1,7 @@
# Created by: Oddbjorn Steffensen <oddbjorn@tricknology.org>
PORTNAME= web2ldap
PORTVERSION= 1.5.117
PORTVERSION= 1.6.4
CATEGORIES= www python
MASTER_SITES= CHEESESHOP https://www.web2ldap.de/download/
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
@ -17,7 +17,7 @@ RUN_DEPENDS= \
${PYTHON_PKGNAMEPREFIX}dnspython2>=2.0.0:dns/py-dnspython2@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}xlwt>0:textproc/py-xlwt@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pillow>0:graphics/py-pillow@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}ldap0>=1.0.1:net/py-ldap0@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}ldap0>=1.2.8:net/py-ldap0@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}defusedxml>0:devel/py-defusedxml@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}prometheus-client>=0.7.1:net-mgmt/py-prometheus-client@${PY_FLAVOR} \
${LOCALBASE}/etc/mime.types:misc/mime-support

View File

@ -1,3 +1,3 @@
TIMESTAMP = 1619466863
SHA256 (web2ldap-1.5.117.tar.gz) = 078cbd9fe1ab25a1a9c69498b946a46e38d985e79bdf1a71633b607417c5515a
SIZE (web2ldap-1.5.117.tar.gz) = 525586
TIMESTAMP = 1621954485
SHA256 (web2ldap-1.6.4.tar.gz) = 334add4635a49cc53fdbd3c986d564e2217f789ff64b33e3acec711ecdfaee87
SIZE (web2ldap-1.6.4.tar.gz) = 527336

View File

@ -0,0 +1,26 @@
--- web2ldap/__init__.py.orig 2021-05-14 15:57:24 UTC
+++ web2ldap/__init__.py
@@ -20,21 +20,13 @@ import time
from .log import logger, LogHelper
from .__about__ import __version__
-# prefixes considered to indicate system-wide installation outside a venv
-OS_SYS_PREFIXES = {
- '/usr',
- '/usr/local',
-}
-
# Path name of [web2ldap]/etc/web2ldap
if 'WEB2LDAP_HOME' in os.environ:
# env var points to web2ldap root directory
ETC_DIR = os.path.join(os.environ['WEB2LDAP_HOME'], 'etc', 'web2ldap')
-elif os.name == 'posix' and sys.prefix in OS_SYS_PREFIXES:
- # assume OS-wide installation on POSIX platform (Linux, BSD, etc.)
- ETC_DIR = '/etc/web2ldap'
else:
- # virtual env
+ # assume OS-wide installation on POSIX platform (Linux, BSD, etc.)
+ # or virtual env
ETC_DIR = os.path.join(sys.prefix, 'etc', 'web2ldap')
sys.path.append(ETC_DIR)

View File

@ -1,29 +0,0 @@
--- web2ldap/app/core.py.orig 2020-05-04 11:51:59 UTC
+++ web2ldap/app/core.py
@@ -19,12 +19,6 @@ import time
import web2ldap.__about__
from web2ldap.log import logger
-# prefixes considered to indicate system-wide installation outside a venv
-OS_SYS_PREFIXES = {
- '/usr',
- '/usr/local',
-}
-
logger.info('Starting web2ldap %s', web2ldap.__about__.__version__)
# this has to be done before import module package ldap0
os.environ['LDAPNOINIT'] = '1'
@@ -39,11 +33,9 @@ check_inst()
if 'WEB2LDAP_HOME' in os.environ:
# env var points to web2ldap root directory
etc_dir = os.path.join(os.environ['WEB2LDAP_HOME'], 'etc', 'web2ldap')
-elif os.name == 'posix' and sys.prefix in OS_SYS_PREFIXES:
- # assume OS-wide installation on POSIX platform (Linux, BSD, etc.)
- etc_dir = '/etc/web2ldap'
else:
- # virtual env
+ # assume OS-wide installation on POSIX platform (Linux, BSD, etc.)
+ # or virtual env
etc_dir = os.path.join(sys.prefix, 'etc', 'web2ldap')
# Default directory for [web2ldap]/etc/web2ldap/templates