config

OpenBSD system configuration
git clone git://jacobedwards.org/config
Log | Files | Refs | README

commit 6580d22ede48f491356bf2320fed867ab82f2644
parent eb96fad2fa7f6952d73e3616c461f37062cd3643
Author: Jacob R. Edwards <n/a>
Date:   Sat,  5 Feb 2022 16:02:02 -0800

Add forks framework and dmenu fork

Perhaps this should be a separate project, but for now it will be
here.

Diffstat:
Alocal/src/src/fork/Makefile | 7+++++++
Alocal/src/src/fork/common.mk | 19+++++++++++++++++++
Alocal/src/src/fork/dmenu/Makefile | 7+++++++
Alocal/src/src/fork/dmenu/patches/config.diff | 26++++++++++++++++++++++++++
Alocal/src/src/fork/dmenu/patches/openbsd.diff | 20++++++++++++++++++++
Alocal/src/src/fork/suckless.mk | 12++++++++++++
Alocal/src/src/fork/tar.mk | 9+++++++++
7 files changed, 100 insertions(+), 0 deletions(-)

diff --git a/local/src/src/fork/Makefile b/local/src/src/fork/Makefile @@ -0,0 +1,7 @@ +SUBDIRS =\ + dmenu\ + +all distclean clean patch build install uninstall: +.for SUBDIR in ${SUBDIRS} + cd ${SUBDIR} && make $@ +.endfor diff --git a/local/src/src/fork/common.mk b/local/src/src/fork/common.mk @@ -0,0 +1,19 @@ +# common targets (include first) + +all: build + +distclean: + rm -f ${arc} + +clean: + rm -rf patched ${dir} + +patch: ${dir} + if test -d patches -a '!' -e patched; then \ + for patch in patches/*; do \ + patch -d ${dir} -p 1 < $$patch; \ + done; \ + > patched; \ + fi + +.PHONY: all distclean clean patch diff --git a/local/src/src/fork/dmenu/Makefile b/local/src/src/fork/dmenu/Makefile @@ -0,0 +1,7 @@ +dir = dmenu-5.0 +arc = ${dir}.tar.gz +url = http://dl.suckless.org/tools/${arc} + +.include "../common.mk" +.include "../tar.mk" +.include "../suckless.mk" diff --git a/local/src/src/fork/dmenu/patches/config.diff b/local/src/src/fork/dmenu/patches/config.diff @@ -0,0 +1,26 @@ +--- /dev/null Sat Feb 5 14:29:28 2022 ++++ config.h Sat Feb 5 14:28:59 2022 +@@ -0,0 +1,23 @@ ++/* See LICENSE file for copyright and license details. */ ++/* Default settings; can be overriden by command line. */ ++ ++static int topbar = 1; /* -b option; if 0, dmenu appears at bottom */ ++/* -fn option overrides fonts[0]; default X11 font or font set */ ++static const char *fonts[] = { ++ "monospace:size=10" ++}; ++static const char *prompt = NULL; /* -p option; prompt to the left of input field */ ++static const char *colors[SchemeLast][2] = { ++ /* fg bg */ ++ [SchemeNorm] = { "#FFFFFF", "#000000" }, ++ [SchemeSel] = { "#000000", "#FFFFFF" }, ++ [SchemeOut] = { "#FFFFFF", "#555555" } ++}; ++/* -l option; if nonzero, dmenu uses vertical list with given number of lines */ ++static unsigned int lines = 16; ++ ++/* ++ * Characters not considered part of a word while deleting words ++ * for example: " /?\"&[]" ++ */ ++static const char worddelimiters[] = " "; diff --git a/local/src/src/fork/dmenu/patches/openbsd.diff b/local/src/src/fork/dmenu/patches/openbsd.diff @@ -0,0 +1,20 @@ +--- config.mk.orig Wed Sep 2 09:37:07 2020 ++++ config.mk Sat Feb 5 14:27:25 2022 +@@ -3,7 +3,7 @@ VERSION = 5.0 + + # paths + PREFIX = /usr/local +-MANPREFIX = $(PREFIX)/share/man ++MANPREFIX = $(PREFIX)/man + + X11INC = /usr/X11R6/include + X11LIB = /usr/X11R6/lib +@@ -16,7 +16,7 @@ XINERAMAFLAGS = -DXINERAMA + FREETYPELIBS = -lfontconfig -lXft + FREETYPEINC = /usr/include/freetype2 + # OpenBSD (uncomment) +-#FREETYPEINC = $(X11INC)/freetype2 ++FREETYPEINC = $(X11INC)/freetype2 + + # includes and libs + INCS = -I$(X11INC) -I$(FREETYPEINC) diff --git a/local/src/src/fork/suckless.mk b/local/src/src/fork/suckless.mk @@ -0,0 +1,12 @@ +# targets for suckless projects (and many other make(1) based) + +build: patch + cd ${dir} && make + +install: build + cd ${dir} && make install + +uninstall: + cd ${dir} && make uninstall + +.PHONY: build install uninstall diff --git a/local/src/src/fork/tar.mk b/local/src/src/fork/tar.mk @@ -0,0 +1,9 @@ +# tar archive distribution targets + +${arc}: + curl -SsL -o ${arc} ${url} + +${dir}: ${arc} + case ${arc} in \ + (*.gz) gunzip;; \ + esac < ${arc} | pax -r