From 7a4663f3dd35a2ecdee7acf07d1c9851eda92adc Mon Sep 17 00:00:00 2001 From: dhn Date: Wed, 28 Dec 2011 15:52:16 +0000 Subject: - Fix build on 7.x Submitted by: garga@ (via mail) --- x11-wm/i3/Makefile | 4 ---- x11-wm/i3/files/patch-i3-config-wizard__main.c | 25 +++++++++++++++++++++++++ 2 files changed, 25 insertions(+), 4 deletions(-) create mode 100644 x11-wm/i3/files/patch-i3-config-wizard__main.c (limited to 'x11-wm') diff --git a/x11-wm/i3/Makefile b/x11-wm/i3/Makefile index e72cf979061c..83c76652c7e4 100644 --- a/x11-wm/i3/Makefile +++ b/x11-wm/i3/Makefile @@ -53,10 +53,6 @@ MAN1= ${MANUALS} .include -.if ${OSVERSION} < 800000 -BROKEN= fails to compile and install -.endif - post-extract: @cd ${WRKSRC} && ${CP} i3.config config.sample @cd ${WRKSRC} && ${CP} i3.welcome welcome diff --git a/x11-wm/i3/files/patch-i3-config-wizard__main.c b/x11-wm/i3/files/patch-i3-config-wizard__main.c new file mode 100644 index 000000000000..738af4e7858c --- /dev/null +++ b/x11-wm/i3/files/patch-i3-config-wizard__main.c @@ -0,0 +1,25 @@ +--- ./i3-config-wizard/main.c.orig 2011-12-24 16:25:08.000000000 +0100 ++++ ./i3-config-wizard/main.c 2011-12-28 09:38:11.000000000 +0100 +@@ -283,10 +283,11 @@ + + char *line = NULL; + size_t len = 0; +-#if !defined(__APPLE__) ++#if defined(__APPLE__) || (defined(__FreeBSD__) && __FreeBSD_version < 800000) ++ bool head_of_file = true; ++#else + ssize_t read; + #endif +- bool head_of_file = true; + + /* write a header about auto-generation to the output file */ + fputs("# This file has been auto-generated by i3-config-wizard(1).\n", ks_config); +@@ -296,7 +297,7 @@ + fputs("# this file and re-run i3-config-wizard(1).\n", ks_config); + fputs("#\n", ks_config); + +-#if defined(__APPLE__) ++#if defined(__APPLE__) || (defined(__FreeBSD__) && __FreeBSD_version < 800000) + while ((line = fgetln(kc_config, &len)) != NULL) { + #else + while ((read = getline(&line, &len, kc_config)) != -1) { -- cgit