mirror of
				git://git.openwrt.org/openwrt/openwrt.git
				synced 2025-11-03 22:44:27 -05:00 
			
		
		
		
	tools: fix GNU stat detection to prevent it from picking up other things named "gstat" (see #4571)
SVN-Revision: 31059
This commit is contained in:
		
							parent
							
								
									265d0b379a
								
							
						
					
					
						commit
						c49f66675e
					
				@ -101,10 +101,19 @@ $(STAGING_DIR_HOST)/bin/$(1): $(STAGING_DIR)/.prepared
 | 
				
			|||||||
endef
 | 
					endef
 | 
				
			||||||
endif
 | 
					endif
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					$(STAGING_DIR_HOST)/bin/stat: $(STAGING_DIR)/.prepared
 | 
				
			||||||
 | 
						@if stat --version > /dev/null 2>&1; then \
 | 
				
			||||||
 | 
							ln -s `which stat` $@; \
 | 
				
			||||||
 | 
						elif gstat --version > /dev/null 2>&1; then \
 | 
				
			||||||
 | 
							ln -s `which gstat` $@; \
 | 
				
			||||||
 | 
						else \
 | 
				
			||||||
 | 
							echo "GNU stat not found"; \
 | 
				
			||||||
 | 
							false; \
 | 
				
			||||||
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$(eval $(call PrepareCommand,find,gfind find))
 | 
					$(eval $(call PrepareCommand,find,gfind find))
 | 
				
			||||||
$(eval $(call PrepareCommand,md5sum,md5sum $(SCRIPT_DIR)/md5sum))
 | 
					$(eval $(call PrepareCommand,md5sum,md5sum $(SCRIPT_DIR)/md5sum))
 | 
				
			||||||
$(eval $(call PrepareCommand,cp,gcp cp))
 | 
					$(eval $(call PrepareCommand,cp,gcp cp))
 | 
				
			||||||
$(eval $(call PrepareCommand,stat,gstat stat))
 | 
					 | 
				
			||||||
$(eval $(call PrepareCommand,seq,gseq seq))
 | 
					$(eval $(call PrepareCommand,seq,gseq seq))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
$(curdir)/cmddeps = $(patsubst %,$(STAGING_DIR_HOST)/bin/%,find md5sum cp stat seq)
 | 
					$(curdir)/cmddeps = $(patsubst %,$(STAGING_DIR_HOST)/bin/%,find md5sum cp stat seq)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user