git: a50884eef5b4 - 2026Q2 - www/forgejo: Fix non-BINDATA case
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 25 Apr 2026 18:19:08 UTC
The branch 2026Q2 has been updated by des:
URL: https://cgit.FreeBSD.org/ports/commit/?id=a50884eef5b4f3a8b16ec56e0743c2a2578672d6
commit a50884eef5b4f3a8b16ec56e0743c2a2578672d6
Author: Dag-Erling Smørgrav <des@FreeBSD.org>
AuthorDate: 2026-04-25 18:17:36 +0000
Commit: Dag-Erling Smørgrav <des@FreeBSD.org>
CommitDate: 2026-04-25 18:19:04 +0000
www/forgejo: Fix non-BINDATA case
DATADIR is still needed for static assets in the non-BINDATA case.
Point StaticRootPath at it. In the BINDATA case (which is the default),
the assets are linked into the binary and StaticRootPath is not used.
PR: 294619
Fixes: 3686ad021c23 ("www/forgejo: Correct AppWorkPAth")
MFH: 2026Q2
(cherry picked from commit e75690e3147e1f973ad5936934721619ab319754)
---
www/forgejo/Makefile | 5 ++++-
www/forgejo/pkg-plist | 1 +
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/www/forgejo/Makefile b/www/forgejo/Makefile
index a3fcdd3a48f6..3d0e5fdbb41f 100644
--- a/www/forgejo/Makefile
+++ b/www/forgejo/Makefile
@@ -1,7 +1,7 @@
PORTNAME= forgejo
DISTVERSIONPREFIX= v
DISTVERSION= 14.0.4
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= www
MASTER_SITES= https://codeberg.org/forgejo/forgejo/releases/download/${DISTVERSIONFULL}/
DISTNAME= forgejo-src-${DISTVERSION}
@@ -55,6 +55,7 @@ SQLITE_VARS= GO_TAGS+="sqlite sqlite_unlock_notify"
SSP_UNSAFE= true
LDFLAGS= "'-X "forgejo.org/modules/setting.CustomPath=${PREFIX}/etc/forgejo"'" \
+ "'-X "forgejo.org/modules/setting.StaticRootPath=${DATADIR}"'" \
"'-X "forgejo.org/modules/setting.AppWorkPath=${DBDIR}"'"
MAKE_ARGS= GOFLAGS="-buildvcs=false" \
GOPATH=${WRKDIR} \
@@ -88,7 +89,9 @@ do-install:
${STAGEDIR}${ETCDIR}/conf/app.ini.sample
${INSTALL_DATA} ${WRKSRC}/custom/conf/app.example.ini \
${STAGEDIR}${ETCDIR}/conf/app.ini.defaults
+.if ! ${PORT_OPTIONS:MBINDATA}
${MKDIR} ${STAGEDIR}${DATADIR}
+.endif
${MKDIR} ${STAGEDIR}${DBDIR}/data
${MKDIR} ${STAGEDIR}${DBDIR}/forgejo-repositories
${MKDIR} ${STAGEDIR}${LOGDIR}
diff --git a/www/forgejo/pkg-plist b/www/forgejo/pkg-plist
index 1c3cf47e64ce..a6868351c92f 100644
--- a/www/forgejo/pkg-plist
+++ b/www/forgejo/pkg-plist
@@ -1,6 +1,7 @@
@sample %%ETCDIR%%/conf/app.ini.sample
%%ETCDIR%%/conf/app.ini.defaults
sbin/forgejo
+%%NO_BINDATA%%@dir %%DATADIR%%
@dir(git,git,755) %%DBDIR%%
@dir(git,git,755) %%DBDIR%%/data
@dir(git,git,755) %%DBDIR%%/forgejo-repositories