From cb0d932597377a6dbc595dbe13f55c9a2cf1ad00 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Tue, 4 Jan 2022 21:15:13 +0100 Subject: Replace dependency on libsimple with boilerplate code MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- makel.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'makel.c') diff --git a/makel.c b/makel.c index 514be21..eeda146 100644 --- a/makel.c +++ b/makel.c @@ -1,7 +1,13 @@ /* See LICENSE file for copyright and license details. */ #include "common.h" -NUSAGE(EXIT_ERROR, "[-f makefile]"); +const char *argv0 = "makel"; + +static void +usage(void) { + fprintf(stderr, "%s [-f makefile]\n", argv0); + exit(EXIT_ERROR); +} int exit_status = 0; @@ -149,8 +155,6 @@ main(int argc, char *argv[]) size_t nlines; size_t i; - libsimple_default_failure_exit = EXIT_ERROR; - /* make(1) shall support mixing of options and operands (up to --) */ ARGBEGIN { case 'f': -- cgit v1.2.3-70-g09d2