From 800c57e63f9dc2edbdc8c797dad7543676ae8a00 Mon Sep 17 00:00:00 2001 From: Ashish Kumar Yadav Date: Wed, 23 Dec 2020 23:56:34 +0530 Subject: [PATCH] makefile updates --- GNUmakefile | 9 ++++----- README.md | 9 +++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/GNUmakefile b/GNUmakefile index 3fd54fb..73361cc 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -1,9 +1,7 @@ -#PREFIX := /usr/local -PREFIX := ${HOME}/.local +PREFIX := /usr/local CC := gcc CFLAGS := -O3 -Wall -Wextra -CFLAGSEXTRA := -Wno-missing-field-initializers -Wno-unused-parameter X11CFLAGS := $(shell pkg-config --cflags x11) X11LIBS := $(shell pkg-config --libs x11) @@ -11,7 +9,7 @@ X11LIBS := $(shell pkg-config --libs x11) all: dwmblocks sigdwmblocks dwmblocks: dwmblocks.c blocks.h - ${CC} -o $@ ${CFLAGS} ${CFLAGSEXTRA} ${X11CFLAGS} $< ${X11LIBS} + ${CC} -o $@ -Wno-missing-field-initializers -Wno-unused-parameter ${CFLAGS} ${X11CFLAGS} $< ${X11LIBS} sigdwmblocks: sigdwmblocks.c ${CC} -o $@ ${CFLAGS} $< @@ -26,8 +24,9 @@ install: all mkdir -p ${DESTDIR}${PREFIX}/bin install -m 0755 dwmblocks ${DESTDIR}${PREFIX}/bin/dwmblocks install -m 0755 sigdwmblocks ${DESTDIR}${PREFIX}/bin/sigdwmblocks + install -m 0755 xgetrootname ${DESTDIR}${PREFIX}/bin/xgetrootname uninstall: - rm -f ${DESTDIR}${PREFIX}/bin/dwmblocks ${DESTDIR}${PREFIX}/bin/sigdwmblocks + rm -f ${DESTDIR}${PREFIX}/bin/dwmblocks ${DESTDIR}${PREFIX}/bin/sigdwmblocks ${DESTDIR}${PREFIX}/bin/xgetrootname .PHONY: all clean install uninstall diff --git a/README.md b/README.md index c1eb26d..aa90ec8 100644 --- a/README.md +++ b/README.md @@ -48,10 +48,11 @@ debugging. # Installation -Clone the repository and run `make install clean` after getting in the project -directory. By default the program is installed in `$HOME/.local/bin` -(see the [GNUmakefile](GNUmakefile)). If xgetrootname is required run -`make xgetrootname`. +Clone the repository and run +``` +cd dwmblocks +sudo make install clean +``` # Acknowledgements