Received: from out1.migadu.com (out1.migadu.com [91.121.223.63]) by mail-b.sr.ht (Postfix) with ESMTPS id A5B05FF0AF for <~andrewrk/ziglang@lists.sr.ht>; Fri, 16 Oct 2020 22:32:59 +0000 (UTC) Authentication-Results: mail-b.sr.ht; dkim=fail reason="key not found in DNS" (0-bit key) header.d=pixelhero.dev header.i=@pixelhero.dev header.b=krjV1mjX X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pixelhero.dev; s=key1; t=1602887578; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=KrOABLKHGucXN5yclYvGWRwkqT3H9BsLSWM9ZadcqJs=; b=krjV1mjX01LHSOFvoLDNQGCY6BiuWBlQxvxx9bhAF0ltrGw7Um2yPMBLdnLi8EYCt0VAZg 3bekhtYZqkB7IYnVovzhG98Ir4KOyG8Ez2qfz8s6L4aIZrMn68EkXviXoEIDDlkiLkUk1b v67ewWH71kC4Bgu+N9s/Yvrx9dDOU02YNIqBd64Mu8EMOd1Aj4CbOUqMGm5cjLQBOwIslb agpSjeXqvh3rZMQyxXAVb1s7Yc+nXQ3zvJMM0b1MLAr6dvhBt5MevevqdZg6F0IL53eyHm e5ZfUf/L+gChfyjVmyosIK4MRWiKeNdJGdl9Vuae2fgiAu8FrBSmnG0zgeml2A== From: Noam Preil To: ~andrewrk/ziglang@lists.sr.ht Cc: Noam Preil Subject: [PATCH] remove bash dependency (verified with shellcheck) Date: Fri, 16 Oct 2020 18:28:37 -0400 Message-Id: <20201016222837.16089-1-noam@pixelhero.dev> MIME-Version: 1.0 X-Spam-Score: 0.00 Content-Transfer-Encoding: quoted-printable --- build | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/build b/build index 01df883a4..1d646840b 100755 --- a/build +++ b/build @@ -13,10 +13,22 @@ TARGET_OS_AND_ABI=3D${TARGET#*-} # Example: linux-gnu =20 # Here we map the OS from the target triple to the value that CMake expe= cts. TARGET_OS_CMAKE=3D${TARGET_OS_AND_ABI%-*} # Example: linux -TARGET_OS_CMAKE=3D"${TARGET_OS_CMAKE/macos/Darwin}" -TARGET_OS_CMAKE=3D"${TARGET_OS_CMAKE/freebsd/FreeBSD}" -TARGET_OS_CMAKE=3D"${TARGET_OS_CMAKE/windows/Windows}" -TARGET_OS_CMAKE=3D"${TARGET_OS_CMAKE/linux/Linux}" +if [ "$TARGET_OS_CMAKE" =3D "macos" ] +then + TARGET_OS_CMAKE=3DDarwin +fi +if [ "$TARGET_OS_CMAKE" =3D "freebsd" ] +then + TARGET_OS_CMAKE=3DFreeBSD +fi +if [ "$TARGET_OS_CMAKE" =3D "windows" ] +then + TARGET_OS_CMAKE=3DWindows +fi +if [ "$TARGET_OS_CMAKE" =3D "linux" ] +then + TARGET_OS_CMAKE=3DLinux +fi =20 # First build the libraries for Zig to link against, as well as native `= llvm-tblgen`. mkdir -p "$ROOTDIR/out/build-llvm-host" --=20 2.28.0