pkgsrc-WIP-changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
gotosocial: improve package after review by wiz
Module Name: pkgsrc-wip
Committed By: m33 <m33%tok715.net@localhost>
Pushed By: m33
Date: Sun Jun 28 09:28:29 2026 +0000
Changeset: 06de46bde70fa8695908fcdddff6ec86d4192dbd
Modified Files:
gotosocial/Makefile
Log Message:
gotosocial: improve package after review by wiz
Changes:
- Removed unecessary things like PKGREVISION, pre-extract
- Cleanup
- Added INSTALL_UNSTRIPPED flag to no to mimic GoToSocial's production
build
To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=06de46bde70fa8695908fcdddff6ec86d4192dbd
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
diffstat:
gotosocial/Makefile | 26 ++++++++++----------------
1 file changed, 10 insertions(+), 16 deletions(-)
diffs:
diff --git a/gotosocial/Makefile b/gotosocial/Makefile
index 3278ffb797..143c814795 100644
--- a/gotosocial/Makefile
+++ b/gotosocial/Makefile
@@ -1,7 +1,7 @@
# $NetBSD: Makefile,v 1.60 2026/06/05 10:21:54 bsiegert Exp $
-DISTNAME= gotosocial-0.21.3
-PKGREVISION= 12
+DISTNAME= gotosocial-0.21.3-source-code
+PKGNAME= ${DISTNAME:S/-source-code//}
CATEGORIES= www
MASTER_SITES= https://codeberg.org/superseriousbusiness/gotosocial/releases/download/v${PKGVERSION_NOREV}/
SRC_DISTFILE= gotosocial-${PKGVERSION_NOREV}-source-code.tar.gz
@@ -14,18 +14,19 @@ LICENSE= gnu-agpl-v3
USE_TOOLS+= pax tar
-EXTRACT_ONLY= ${SRC_DISTFILE}
-EXTRACT_DIR= ${WRKSRC}
-
ASSETS= gotosocial_${PKGVERSION_NOREV}_web-assets.tar.gz
DISTFILES= ${SRC_DISTFILE} ${ASSETS}
+EXTRACT_ONLY= ${SRC_DISTFILE} ${ASSETS}
+EXTRACT_DIR= ${WRKSRC}
+
MAKE_ENV+= VERSION=${PKGVERSION_NOREV}
BUILD_DEFS+= VARBASE
# Set compilation flags inspired from gotosocial's build.sh
-GOFLAGS+= -trimpath -tags=osusergo,nomsgpack,stdlibjson -ldflags='-s -w -X main.Version=v${PKGVERSION_NOREV}'
-MAKE_ENV+= CGO_ENABLED=0
+GOFLAGS+= -trimpath -tags=osusergo,nomsgpack,stdlibjson -ldflags='-s -w -X main.Version=v${PKGVERSION}'
+MAKE_ENV+= CGO_ENABLED=0
+INSTALL_UNSTRIPPED= no
.include "go-modules.mk"
@@ -57,7 +58,7 @@ CONF_FILES+= ${EGDIR}/config.yaml ${PKG_SYSCONFDIR}/config.yaml
SUBST_CLASSES+= cfg
SUBST_MESSAGE.cfg= Fixing default paths in config
SUBST_STAGE.cfg= post-configure
-SUBST_FILES.cfg= example/config.yaml
+SUBST_FILES.cfg= ${WRKSRC}/example/config.yaml
SUBST_SED.cfg= -e "s,\./web/template/,${GOTOSOCIAL_DATA}/template/,g"
SUBST_SED.cfg+= -e "s,\./web/assets/,${GOTOSOCIAL_DATA}/assets/,g"
SUBST_SED.cfg+= -e "s,/gotosocial/storage,${GOTOSOCIAL_DB}/storage,g"
@@ -65,15 +66,10 @@ SUBST_SED.cfg+= -e "s,/gotosocial/storage,${GOTOSOCIAL_DB}/storage,g"
SUBST_CLASSES+= systemdpaths
SUBST_MESSAGE.systemdpaths= Fixing paths in systemd file
SUBST_STAGE.systemdpaths= post-configure
-SUBST_FILES.systemdpaths= example/gotosocial.service
+SUBST_FILES.systemdpaths= ${WRKSRC}/example/gotosocial.service
SUBST_SED.systemdpaths= -e 's,/gotosocial/gotosocial,${PREFIX}/bin/gotosocial,g'
SUBST_SED.systemdpaths+= -e 's,config.yaml,${PKG_SYSCONFDIR}/config.yaml,g'
-pre-extract:
- ${MKDIR} ${WRKSRC}
-post-extract:
- cd ${WRKSRC} && ${TAR} -xzf ${DISTDIR}/${ASSETS}
-
post-install:
${MKDIR} ${DESTDIR}/${EGDIR}
${INSTALL_DATA} ${WRKSRC}/example/config.yaml ${DESTDIR}/${EGDIR}/config.yaml
@@ -81,10 +77,8 @@ post-install:
${INSTALL_DATA} ${WRKSRC}/example/gotosocial.service ${DESTDIR}/${EGDIR}/gotosocial.service
# Installs the assets source, may not be necessary
cd ${WRKSRC} && ${PAX} -rw web ${DESTDIR}/${EGDIR}
- cd ${WRKSRC} && ${PAX} -rw web ${DESTDIR}/${EGDIR}
# Do not install test/dev binaries
cd ${DESTDIR}${PREFIX}/bin && ${RM} gen process-emoji process-media
- cd ${DESTDIR}${PREFIX}/bin && ${STRIP} -v gotosocial
.include "../../lang/go/go-module.mk"
.include "../../mk/bsd.pkg.mk"
Home |
Main Index |
Thread Index |
Old Index