mirror of
				https://github.com/edera-dev/krata.git
				synced 2025-11-04 07:39:39 +00:00 
			
		
		
		
	krata: rework cross-compilation
This commit is contained in:
		
							
								
								
									
										15
									
								
								hack/build/cross-compile.sh
									
									
									
									
									
										Executable file
									
								
							
							
						
						
									
										15
									
								
								hack/build/cross-compile.sh
									
									
									
									
									
										Executable file
									
								
							@ -0,0 +1,15 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
set -e
 | 
			
		||||
 | 
			
		||||
TOOLS_DIR="$(dirname "${0}")"
 | 
			
		||||
 | 
			
		||||
RUST_TARGET="$("${TOOLS_DIR}/target.sh")"
 | 
			
		||||
TARGET_ARCH="$(echo "${RUST_TARGET}" | awk -F '-' '{print $1}')"
 | 
			
		||||
HOST_ARCH="$(uname -m)"
 | 
			
		||||
 | 
			
		||||
if [ "${HOST_ARCH}" != "${TARGET_ARCH}" ]
 | 
			
		||||
then
 | 
			
		||||
  echo "1"
 | 
			
		||||
else
 | 
			
		||||
  echo "0"
 | 
			
		||||
fi
 | 
			
		||||
		Reference in New Issue
	
	Block a user