Import of pkgsrc-2016Q3

This commit is contained in:
2016-10-14 07:49:11 +02:00
committed by Lionel Sambuc
parent 9d819b6d54
commit 1242aa1e36
35952 changed files with 949749 additions and 377083 deletions

7
sysutils/i3status/DESCR Normal file
View File

@@ -0,0 +1,7 @@
i3status is a small program (about 3000 SLOC) for generating a status bar
for dzen2, xmobar or similar programs. It is designed to be very efficient
by issuing a very small number of system calls, as one generally wants
to update such a status line every second.
This ensures that even under high load, your status bar is updated correctly.
Also, it saves a bit of energy by not hogging your CPU as much as spawning
the corresponding amount of shell commands would.

View File

@@ -0,0 +1,34 @@
# $NetBSD: Makefile,v 1.3 2016/08/04 17:03:38 ryoon Exp $
#
DISTNAME= i3status-2.10
PKGREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= http://i3wm.org/i3status/
EXTRACT_SUFX= .tar.bz2
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://i3wm.org/i3status/
COMMENT= Small program for generating a status bar
LICENSE= modified-bsd
USE_TOOLS+= gmake
CONF_FILES= ${PREFIX}/share/examples/${PKGBASE}/i3status.conf ${PKG_SYSCONFDIR}/i3status.conf
BUILD_DEFS+= VARBASE
MAKE_ENV+= MANDIR=${PKGMANDIR}
MAKE_ENV+= SYSCONFDIR=${PKG_SYSCONFDIR}
MAKE_ENV+= DEBUG=0
SUBST_CLASSES+= fix-paths
SUBST_STAGE.fix-paths= pre-configure
SUBST_MESSAGE.fix-paths= Fixing absolute paths.
SUBST_FILES.fix-paths= i3status.conf
SUBST_SED.fix-paths+= -e 's,/var,${VARBASE},g'
.include "../../devel/confuse/buildlink3.mk"
.include "../../devel/yajl/buildlink3.mk"
.include "../../audio/pulseaudio/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"

5
sysutils/i3status/PLIST Normal file
View File

@@ -0,0 +1,5 @@
@comment $NetBSD: PLIST,v 1.1 2016/06/14 06:39:37 kamil Exp $
bin/i3status
man/man1/i3status.1
share/doc/i3status/LICENSE
share/examples/i3status/i3status.conf

View File

@@ -0,0 +1,9 @@
$NetBSD: distinfo,v 1.1 2016/06/14 06:39:37 kamil Exp $
SHA1 (i3status-2.10.tar.bz2) = b0bfcac24c9e57958eefd9c3b00aed4b73b2c708
RMD160 (i3status-2.10.tar.bz2) = 78a2d26aea8d59e8b8e9f7a302e28688bd9ae516
SHA512 (i3status-2.10.tar.bz2) = a514331d83458de15b548686d423b38a7a9198a7a31ca3001f3f136e4b873617c397a0073bb10b44fa8613bc12ed4fa4e384d099d31122a8afbd0df5de2e9c85
Size (i3status-2.10.tar.bz2) = 53684 bytes
SHA1 (patch-Makefile) = 2ca0cf79670e189a7e70e14247b1cd4aafb81ffd
SHA1 (patch-src_print__disk__info.c) = e0662f65b21402e60a643374898707f5807077f2
SHA1 (patch-src_print__wireless__info.c) = 4632c9eabd5b5d73bc67e541bf7dc93e883339d1

View File

@@ -0,0 +1,36 @@
$NetBSD: patch-Makefile,v 1.1 2016/06/14 06:39:37 kamil Exp $
Adjust paths and install LICENSE.
--- Makefile.orig 2016-01-01 18:51:19.000000000 +0000
+++ Makefile
@@ -11,6 +11,9 @@ ifndef SYSCONFDIR
SYSCONFDIR=$(PREFIX)/etc
endif
endif
+ifndef MANDIR
+ MANDIR=$(MANDIR)
+endif
CFLAGS+=-Wall -Wshadow -Wpointer-arith -Wcast-qual -Wsign-compare
CFLAGS+=-g
@@ -100,13 +103,15 @@ manpage:
install:
install -m 755 -d $(DESTDIR)$(PREFIX)/bin
- install -m 755 -d $(DESTDIR)$(SYSCONFDIR)
- install -m 755 -d $(DESTDIR)$(MANPREFIX)/share/man/man1
+ install -m 755 -d $(DESTDIR)$(PREFIX)/share/examples/i3status
+ install -m 755 -d $(DESTDIR)$(PREFIX)/share/doc/i3status
+ install -m 755 -d $(DESTDIR)$(MANPREFIX)/$(MANDIR)/man1
install -m 755 i3status $(DESTDIR)$(PREFIX)/bin/i3status
# Allow network configuration for getting the link speed
(which setcap && setcap cap_net_admin=ep $(DESTDIR)$(PREFIX)/bin/i3status) || true
- install -m 644 i3status.conf $(DESTDIR)$(SYSCONFDIR)/i3status.conf
- install -m 644 man/i3status.1 $(DESTDIR)$(MANPREFIX)/share/man/man1
+ install -m 644 i3status.conf $(DESTDIR)$(PREFIX)/share/examples/i3status/i3status.conf
+ install -m 644 LICENSE $(DESTDIR)$(PREFIX)/share/doc/i3status
+ install -m 644 man/i3status.1 $(DESTDIR)$(MANPREFIX)/$(MANDIR)/man1
release:
[ -f i3status-${VERSION} ] || rm -rf i3status-${VERSION}

View File

@@ -0,0 +1,53 @@
$NetBSD: patch-src_print__disk__info.c,v 1.1 2016/06/14 06:39:37 kamil Exp $
* mntent.h and setmntent stuff is linux only
* NetBSD has statvfs structure, not statfs
--- src/print_disk_info.c.orig 2016-01-01 18:51:19.000000000 +0000
+++ src/print_disk_info.c
@@ -7,11 +7,11 @@
#include <sys/stat.h>
#include <sys/statvfs.h>
#include <sys/types.h>
-#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || (__OpenBSD__) || defined(__DragonFly__) || defined(__APPLE__)
+#if defined(__linux__)
+#include <mntent.h>
+#else
#include <sys/param.h>
#include <sys/mount.h>
-#else
-#include <mntent.h>
#endif
#include <yajl/yajl_gen.h>
#include <yajl/yajl_version.h>
@@ -116,12 +116,7 @@ void print_disk_info(yajl_gen json_gen,
INSTANCE(path);
-#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__OpenBSD__) || defined(__DragonFly__) || defined(__APPLE__)
- struct statfs buf;
-
- if (statfs(path, &buf) == -1)
- return;
-#else
+#if defined(__linux__)
struct statvfs buf;
if (statvfs(path, &buf) == -1) {
@@ -145,6 +140,16 @@ void print_disk_info(yajl_gen json_gen,
format = format_not_mounted;
}
}
+#elif defined(__NetBSD__)
+ struct statvfs buf;
+
+ if (statvfs(path, &buf) == -1)
+ format = format_not_mounted;
+#else
+ struct statfs buf;
+
+ if (statfs(path, &buf) == -1)
+ return;
#endif
if (low_threshold > 0 && below_threshold(buf, prefix_type, threshold_type, low_threshold)) {

View File

@@ -0,0 +1,19 @@
$NetBSD: patch-src_print__wireless__info.c,v 1.1 2016/06/14 06:39:37 kamil Exp $
Add support for NetBSD.
--- src/print_wireless_info.c.orig 2016-01-01 18:51:19.000000000 +0000
+++ src/print_wireless_info.c
@@ -52,6 +52,12 @@
#include <net80211/ieee80211_ioctl.h>
#endif
+#ifdef __NetBSD__
+#include <unistd.h>
+#include <net80211/ieee80211.h>
+#define IW_ESSID_MAX_SIZE IEEE80211_NWID_LEN
+#endif
+
#include "i3status.h"
#define WIRELESS_INFO_FLAG_HAS_ESSID (1 << 0)