summaryrefslogtreecommitdiff
path: root/x11/mons
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2023-05-12 08:21:46 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2023-05-12 08:21:46 +0000
commitf1a221f38e050d365327449754490ab954af65f9 (patch)
treef440ebe1e80f7a6e23e269da94a02da702331f8a /x11/mons
parent2495f4fa5120df95fac7c96805b2eddb9d92a6e3 (diff)
downloadfreebsd-ports-f1a221f38e050d365327449754490ab954af65f9.zip
x11/mons: the port had been improved (+)
Patch the Makefile the right way and remove MAKE_ARGS: let our framework deal with the LICENSE file, pass correct DESTDIR and PREFIX values, and create the symlink to `liblist.sh' where it is expected.
Diffstat (limited to 'x11/mons')
-rw-r--r--x11/mons/Makefile6
-rw-r--r--x11/mons/files/patch-Makefile36
2 files changed, 24 insertions, 18 deletions
diff --git a/x11/mons/Makefile b/x11/mons/Makefile
index 76415711ca78..8a1da3d8c116 100644
--- a/x11/mons/Makefile
+++ b/x11/mons/Makefile
@@ -11,7 +11,7 @@ LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE
BUILD_DEPENDS= help2man:misc/help2man
-RUN_DEPENDS= xrandr>0:x11/xrandr
+RUN_DEPENDS= xrandr:x11/xrandr
USE_GITHUB= yes
GH_ACCOUNT= Ventto
@@ -21,10 +21,6 @@ GH_SUBDIR= libshlist:libshlist
NO_ARCH= yes
NO_BUILD= yes
-MAKE_ARGS= DESTDIR=${STAGEDIR} \
- PREFIX=${PREFIX} \
- MANDIR=${STAGEDIR}${PREFIX}/man/man1 \
- LIB=${WRKSRC_libshlist}/liblist.sh
OPTIONS_DEFINE= DOCS
diff --git a/x11/mons/files/patch-Makefile b/x11/mons/files/patch-Makefile
index 11d94bf9299b..e63630a59a18 100644
--- a/x11/mons/files/patch-Makefile
+++ b/x11/mons/files/patch-Makefile
@@ -1,22 +1,32 @@
--- Makefile.orig 2017-11-25 13:46:52 UTC
+++ Makefile
-@@ -1,11 +1,12 @@
--PKGNAME = mons
--PKGDESC = POSIX Shell script to quickly manage 2-monitors display.
-+PKGNAME = mons
-+PKGDESC = POSIX Shell script to quickly manage 2-monitors display.
+@@ -1,10 +1,9 @@
+ PKGNAME = mons
+ PKGDESC = POSIX Shell script to quickly manage 2-monitors display.
-LICENSEDIR = $(DESTDIR)/usr/share/licenses/$(PKGNAME)
-MANDIR = $(DESTDIR)/usr/share/man/man1
-BINDIR = $(DESTDIR)/usr/bin
-LIBDIR = $(DESTDIR)/usr/lib/libshlist
--LIB = libshlist/liblist.sh
-+PREFIX = /usr
-+LICENSEDIR = $(DESTDIR)$(PREFIX)/share/licenses/$(PKGNAME)
-+MANDIR = $(DESTDIR)$(PREFIX)/share/man/man1
-+BINDIR = $(DESTDIR)$(PREFIX)/bin
-+LIBDIR = $(DESTDIR)$(PREFIX)/lib/libshlist
-+LIB = libshlist/liblist.sh
++MANDIR = $(DESTDIR)$(PREFIX)/man/man1
++BINDIR = $(DESTDIR)$(PREFIX)/bin
++LIBDIR = $(DESTDIR)$(PREFIX)/lib/libshlist
+ LIB = libshlist/liblist.sh
install:
- @if ! [ -r "$(LIB)" ]; then \
+@@ -18,15 +17,12 @@ install:
+ exit 1; \
+ fi
+ mkdir -p $(MANDIR)
+- mkdir -p $(LICENSEDIR)
+ mkdir -p $(LIBDIR)
+ mkdir -p $(BINDIR)
+ chmod 644 $(PKGNAME).1.gz
+- chmod 644 LICENSE
+ chmod 644 $(LIB)
+ chmod 755 mons
+ cp $(PKGNAME).1.gz $(MANDIR)/$(PKGNAME).1.gz
+- cp LICENSE $(LICENSEDIR)/LICENSE
+ cp $(LIB) $(LIBDIR)/liblist.sh
+ cp mons $(BINDIR)/mons
+