gnu: libx264: Fix building on riscv64-linux.
* gnu/packages/video.scm (libx264)[inputs]: Add config. [arguments]: Adjust configure-flags to always build PIC code. Add custom phase to replace config.guess, config.sub scripts.
This commit is contained in:
		
							parent
							
								
									b43c3a745c
								
							
						
					
					
						commit
						10abb05190
					
				
					 1 changed files with 14 additions and 1 deletions
				
			
		| 
						 | 
				
			
			@ -904,6 +904,8 @@ shared library and encoder and decoder command-line executables.")
 | 
			
		|||
      (build-system gnu-build-system)
 | 
			
		||||
      (native-inputs
 | 
			
		||||
       (list pkg-config nasm))
 | 
			
		||||
      (inputs
 | 
			
		||||
       (list config))
 | 
			
		||||
      ;; TODO: Add gpac input
 | 
			
		||||
      (arguments
 | 
			
		||||
       `(#:tests? #f                    ;no check target
 | 
			
		||||
| 
						 | 
				
			
			@ -914,6 +916,7 @@ shared library and encoder and decoder command-line executables.")
 | 
			
		|||
                             ;; program depends on ffmpeg and ffmpeg depends on
 | 
			
		||||
                             ;; libx264).
 | 
			
		||||
                             "--disable-cli"
 | 
			
		||||
                             "--enable-pic"
 | 
			
		||||
 | 
			
		||||
                             ;; On MIPS, we must pass "--disable-asm" or else
 | 
			
		||||
                             ;; configure fails after printing: "You specified a
 | 
			
		||||
| 
						 | 
				
			
			@ -924,7 +927,17 @@ shared library and encoder and decoder command-line executables.")
 | 
			
		|||
                                                   (or (%current-target-system)
 | 
			
		||||
                                                       (%current-system)))
 | 
			
		||||
                                   '("--disable-asm")
 | 
			
		||||
                                   '()))))
 | 
			
		||||
                                   '()))
 | 
			
		||||
         #:phases
 | 
			
		||||
         (modify-phases %standard-phases
 | 
			
		||||
           (add-after 'unpack 'update-config-scripts
 | 
			
		||||
             (lambda* (#:key native-inputs inputs #:allow-other-keys)
 | 
			
		||||
               (for-each (lambda (file)
 | 
			
		||||
                               (install-file
 | 
			
		||||
                                 (search-input-file
 | 
			
		||||
                                   (or native-inputs inputs)
 | 
			
		||||
                                   (string-append "/bin/" file)) "."))
 | 
			
		||||
                         '("config.guess" "config.sub")))))))
 | 
			
		||||
      (home-page "https://www.videolan.org/developers/x264.html")
 | 
			
		||||
      (synopsis "H.264 video coding library")
 | 
			
		||||
      (description "libx264 is an advanced encoding library for creating
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Reference in a new issue