gnu: libinih: Build & install static libraries.
* gnu/packages/linux.scm (libinih)[outputs]: Add "static". [arguments]: Substitute "-Ddefault_library=both" for the "-Ddefault_library=shared" configure flag. Add a new 'separate-static phase.
This commit is contained in:
		
							parent
							
								
									15489291d9
								
							
						
					
					
						commit
						31a3c9b441
					
				
					 1 changed files with 17 additions and 1 deletions
				
			
		|  | @ -7657,8 +7657,24 @@ IP addresses and routes, and configure IPsec.") | ||||||
|                (base32 |                (base32 | ||||||
|                 "0dqf5j2sw4hq68rqvxbrsf44ygfzx9ypiyzipk4cvp9aimbvsbc6")))) |                 "0dqf5j2sw4hq68rqvxbrsf44ygfzx9ypiyzipk4cvp9aimbvsbc6")))) | ||||||
|     (build-system meson-build-system) |     (build-system meson-build-system) | ||||||
|  |     ;; Install static libraries for use by the initrd's xfsprogs/static. | ||||||
|  |     (outputs (list "out" "static")) | ||||||
|     (arguments |     (arguments | ||||||
|      '(#:configure-flags '("-Ddistro_install=true" "-Ddefault_library=shared"))) |      `(#:configure-flags | ||||||
|  |        (list "-Ddistro_install=true" | ||||||
|  |              "-Ddefault_library=both") | ||||||
|  |        #:phases | ||||||
|  |        (modify-phases %standard-phases | ||||||
|  |          (add-after 'install 'separate-static | ||||||
|  |            (lambda* (#:key outputs #:allow-other-keys) | ||||||
|  |              (let ((out    (assoc-ref outputs "out")) | ||||||
|  |                    (static (assoc-ref outputs "static"))) | ||||||
|  |                (with-directory-excursion out | ||||||
|  |                  (for-each (lambda (source) | ||||||
|  |                              (let ((target (string-append static "/" source))) | ||||||
|  |                                (mkdir-p (dirname target)) | ||||||
|  |                                (rename-file source target))) | ||||||
|  |                            (find-files "lib" "\\.a$"))))))))) | ||||||
|     (home-page "https://github.com/benhoyt/inih") |     (home-page "https://github.com/benhoyt/inih") | ||||||
|     (synopsis "Simple .INI parser library for C") |     (synopsis "Simple .INI parser library for C") | ||||||
|     (description "The inih (INI Not Invented Here) library is a simple .INI file |     (description "The inih (INI Not Invented Here) library is a simple .INI file | ||||||
|  |  | ||||||
		Reference in a new issue