···493493 echo "-arch ${targetPlatform.darwinArch}" >> $out/nix-support/cc-cflags
494494 ''
495495496496+ + optionalString targetPlatform.isAndroid ''
497497+ echo "-D__ANDROID_API__=${targetPlatform.sdkVer}" >> $out/nix-support/cc-cflags
498498+ ''
499499+496500 # There are a few tools (to name one libstdcxx5) which do not work
497501 # well with multi line flags, so make the flags single line again
498502 + ''
···11+--- a/libc/include/android/ndk-version.h 2021-04-01 16:08:03.109183965 +0300
22++++ b/libc/include/android/ndk-version.h 2021-04-01 16:07:19.811424641 +0300
33+@@ -0,0 +1,39 @@
44++#pragma once
55++
66++/**
77++ * Set to 1 if this is an NDK, unset otherwise. See
88++ * https://android.googlesource.com/platform/bionic/+/master/docs/defines.md.
99++ */
1010++#define __ANDROID_NDK__ 1
1111++
1212++/**
1313++ * Major version of this NDK.
1414++ *
1515++ * For example: 16 for r16.
1616++ */
1717++#define __NDK_MAJOR__ 22
1818++
1919++/**
2020++ * Minor version of this NDK.
2121++ *
2222++ * For example: 0 for r16 and 1 for r16b.
2323++ */
2424++#define __NDK_MINOR__ 0
2525++
2626++/**
2727++ * Set to 0 if this is a release build, or 1 for beta 1,
2828++ * 2 for beta 2, and so on.
2929++ */
3030++#define __NDK_BETA__ 0
3131++
3232++/**
3333++ * Build number for this NDK.
3434++ *
3535++ * For a local development build of the NDK, this is -1.
3636++ */
3737++#define __NDK_BUILD__ 7026061
3838++
3939++/**
4040++ * Set to 1 if this is a canary build, 0 if not.
4141++ */
4242++#define __NDK_CANARY__ 0