mirror of
				https://github.com/Cisco-Talos/clamav.git
				synced 2025-11-04 01:50:56 +00:00 
			
		
		
		
	CMake: curses detection with-or-without pkg-config
FreeBSD and OpenBSD package maintainers identified failures when pkg-config .pc files not present for curses/ncurses. Patch courtesy of Stuart Henderson.
This commit is contained in:
		
							parent
							
								
									74cbfc62ad
								
							
						
					
					
						commit
						d4a5f9f77e
					
				
					 1 changed files with 8 additions and 2 deletions
				
			
		| 
						 | 
					@ -58,8 +58,14 @@ if(NCURSES_NOT_FOUND EQUAL -1)
 | 
				
			||||||
    set(HAVE_LIBNCURSES 1)
 | 
					    set(HAVE_LIBNCURSES 1)
 | 
				
			||||||
    set(CURSES_INCLUDE "<ncurses.h>")
 | 
					    set(CURSES_INCLUDE "<ncurses.h>")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    set(CURSES_LIBRARY ${PC_NCurses_LINK_LIBRARIES})
 | 
					    if (DEFINED PC_NCurses_LINK_LIBRARIES)
 | 
				
			||||||
    set(CURSES_VERSION ${PC_NCurses_VERSION})
 | 
					        set(CURSES_LIBRARY ${PC_NCurses_LINK_LIBRARIES})
 | 
				
			||||||
 | 
					    else()
 | 
				
			||||||
 | 
					        find_library(CURSES_LIBRARY
 | 
				
			||||||
 | 
					            NAMES ncurses
 | 
				
			||||||
 | 
					            PATHS ${PC_NCurses_LIBRARY_DIRS}
 | 
				
			||||||
 | 
					        )
 | 
				
			||||||
 | 
					    endif()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    include(FindPackageHandleStandardArgs)
 | 
					    include(FindPackageHandleStandardArgs)
 | 
				
			||||||
    find_package_handle_standard_args(CURSES
 | 
					    find_package_handle_standard_args(CURSES
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue