From 2bfe0bc5ae22768f6435c64d986e70938635d8c2 Mon Sep 17 00:00:00 2001 From: Juhani Krekelä Date: Sat, 26 Jun 2021 22:23:29 +0300 Subject: Make Makefile portable Currently weltschmerz's make-based build system relies on GNU make extensions. Change it to only use POSIX and other nearly universally implemented features. A small downside to this patch is that .po files must be listed in the Makefile manually. --- Makefile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index d00146a..5346a0d 100644 --- a/Makefile +++ b/Makefile @@ -6,9 +6,12 @@ LOCALEDIR ?= ${DATAROOTDIR}/locale MANDIR ?= ${DATAROOTDIR}/man VALAC ?= valac -POFILES := $(wildcard po/*.po) +POFILES := po/de.po MOFILES := $(POFILES:.po=.mo) +.SUFFIXES: +.SUFFIXES: .po .mo + all: weltschmerz weltschmerz.1 weltschmerz.desktop $(MOFILES) weltschmerz: weltschmerz.vala terminal.vala config.vala configreader.vala utils.vala resources.c @@ -19,7 +22,7 @@ weltschmerz: weltschmerz.vala terminal.vala config.vala configreader.vala utils. resources.c: resources.xml terminal.ui terminal.css glib-compile-resources $< --target=$@ --generate-source -%.mo: %.po +.po.mo: msgfmt $< -o $@ weltschmerz.desktop: weltschmerz.desktop.in -- cgit v1.2.3-2-gb3c3