mirror of
				https://github.com/YosysHQ/yosys
				synced 2025-11-03 21:09:12 +00:00 
			
		
		
		
	Suppress output of Makefile.conf when printing source versions
The make targets echo-yosys-ver, echo-git-ver and echo-abc-rev can be used to programmatically extract contents of make variables for external scripts. Unfortunately, when a Makefile.conf exists, its contents would also be echoed, making the output almost unusable. This patch selectively disables this functionality for these special targets.
This commit is contained in:
		
							parent
							
								
									93ef516d91
								
							
						
					
					
						commit
						333981acfd
					
				
					 1 changed files with 3 additions and 0 deletions
				
			
		
							
								
								
									
										3
									
								
								Makefile
									
										
									
									
									
								
							
							
						
						
									
										3
									
								
								Makefile
									
										
									
									
									
								
							| 
						 | 
				
			
			@ -148,7 +148,10 @@ define newline
 | 
			
		|||
endef
 | 
			
		||||
 | 
			
		||||
ifneq ($(wildcard Makefile.conf),)
 | 
			
		||||
# don't echo Makefile.conf contents when invoked to print source versions
 | 
			
		||||
ifeq ($(findstring echo-,$(MAKECMDGOALS)),)
 | 
			
		||||
$(info $(subst $$--$$,$(newline),$(shell sed 's,^,[Makefile.conf] ,; s,$$,$$--$$,;' < Makefile.conf | tr -d '\n' | sed 's,\$$--\$$$$,,')))
 | 
			
		||||
endif
 | 
			
		||||
include Makefile.conf
 | 
			
		||||
endif
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue