gnu: slim: Fix build failure with GCC-11
GCC-11 sniffed out a long-standing bug where a pointer was being tested for a negative value, which is impossible. Instead, check for NULL, which is how the error result is actually returned. See https://github.com/iwamatsu/slim/issues/14 for details. Fixes <https://issues.guix.gnu.org/63155>. * gnu/packages/display-managers.scm (slim) [fix-0-pointer-comparison]: new phase Signed-off-by: Ludovic Courtès <ludo@gnu.org>
This commit is contained in:
		
							parent
							
								
									5cb04b570f
								
							
						
					
					
						commit
						efce51a194
					
				
					 1 changed files with 5 additions and 1 deletions
				
			
		| 
						 | 
					@ -475,7 +475,11 @@ GTK+, lets you select a desktop session and log in to it.")
 | 
				
			||||||
               ;; The build system's logic here is: if "Linux", then
 | 
					               ;; The build system's logic here is: if "Linux", then
 | 
				
			||||||
                ;; "systemd".  Strip that.
 | 
					                ;; "systemd".  Strip that.
 | 
				
			||||||
                ""))
 | 
					                ""))
 | 
				
			||||||
             #t)))
 | 
					             #t))
 | 
				
			||||||
 | 
					         (add-before 'configure 'fix-0-pointer-comparison
 | 
				
			||||||
 | 
					           (lambda _
 | 
				
			||||||
 | 
					             (substitute* "panel.cpp"
 | 
				
			||||||
 | 
					               (("WinGC < 0") "WinGC == NULL")))))
 | 
				
			||||||
       #:configure-flags '("-DUSE_PAM=yes"
 | 
					       #:configure-flags '("-DUSE_PAM=yes"
 | 
				
			||||||
                           "-DUSE_CONSOLEKIT=no")
 | 
					                           "-DUSE_CONSOLEKIT=no")
 | 
				
			||||||
       #:tests? #f))
 | 
					       #:tests? #f))
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Reference in a new issue