 955bca6574
			
		
	
	
		955bca6574
		
	
	
	
	
		
			
			We have strings containing hardcoded ".dylib" extensions in homebrew-core. To be able to bring linuxbrew-core and homebrew-core closer together, I am introducing a new generic attribute that can be used in formulae.
		
			
				
	
	
		
			18 lines
		
	
	
		
			263 B
		
	
	
	
		
			Ruby
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
		
			263 B
		
	
	
	
		
			Ruby
		
	
	
	
	
	
| # frozen_string_literal: true
 | |
| 
 | |
| class Formula
 | |
|   undef shared_library
 | |
| 
 | |
|   def shared_library(name, version = nil)
 | |
|     "#{name}.so#{"." unless version.nil?}#{version}"
 | |
|   end
 | |
| 
 | |
|   class << self
 | |
|     undef on_linux
 | |
| 
 | |
|     def on_linux(&_block)
 | |
|       yield
 | |
|     end
 | |
|   end
 | |
| end
 |