diff options
-rw-r--r-- | awesome.scm | 35 | ||||
-rw-r--r-- | patches/awesome-screen.patch | 13 |
2 files changed, 48 insertions, 0 deletions
diff --git a/awesome.scm b/awesome.scm new file mode 100644 index 0000000..8f8a36c --- /dev/null +++ b/awesome.scm @@ -0,0 +1,35 @@ +(define-module (awesome) + #:use-module (guix packages) + #:use-module (guix download) + #:use-module (gnu packages) + #:use-module (gnu packages wm)) + +(define-public patched-awesome + (let ((version (package-version awesome))) + (package + (inherit awesome) + (name "patched-awesome") + (source + (origin + (method url-fetch) + (uri (string-append + "https://github.com/awesomeWM/awesome-releases/raw/" + "master/awesome-" version ".tar.xz")) + (sha256 + (base32 + "0kwpbls9h1alxcmvxh5g9qb995fds5b2ngcr44w0ibazkyls2pdc")) + (modules '((guix build utils) + (srfi srfi-19))) + (snippet '(begin + ;; Remove non-reproducible timestamp and use the date + ;; of the source file instead. + (substitute* "common/version.c" + (("__DATE__ \" \" __TIME__") + (date->string + (time-utc->date + (make-time time-utc 0 + (stat:mtime (stat "awesome.c")))) + "\"~c\""))) + #t)) + (patches (search-patches "awesome-reproducible-png.patch" + "patches/awesome-screen.patch"))))))) diff --git a/patches/awesome-screen.patch b/patches/awesome-screen.patch new file mode 100644 index 0000000..969fffe --- /dev/null +++ b/patches/awesome-screen.patch @@ -0,0 +1,13 @@ +diff --git a/objects/screen.c b/objects/screen.c +index 93ce2288f..0da47e362 100644 +--- a/objects/screen.c ++++ b/objects/screen.c +@@ -670,7 +670,7 @@ screen_refresh(void) + } + + /* Remove screens which are gone */ +- for(int i = 0; i < globalconf.screens.len; i++) { ++ for(int i = 0; i < globalconf.screens.len && globalconf.screens.len > 1; i++) { + screen_t *old_screen = globalconf.screens.tab[i]; + bool found = false; + foreach(new_screen, new_screens)
\ No newline at end of file |