Add and use constants for the Android API levels.
Test: bionic tests still pass
Change-Id: If1b619cfc9db1d3f5d91f14f2ace71058dca0c4a
diff --git a/libc/include/stdlib.h b/libc/include/stdlib.h
index c84460b..d0c08e1 100644
--- a/libc/include/stdlib.h
+++ b/libc/include/stdlib.h
@@ -152,7 +152,7 @@
size_t wcstombs(char*, const wchar_t*, size_t);
-#if __ANDROID_API__ >= 21
+#if __ANDROID_API__ >= __ANDROID_API_L__
size_t __ctype_get_mb_cur_max(void) __INTRODUCED_IN(21);
#define MB_CUR_MAX __ctype_get_mb_cur_max()
#else
@@ -184,7 +184,7 @@
#endif /* defined(__BIONIC_FORTIFY) */
-#if __ANDROID_API__ >= 21
+#if __ANDROID_API__ >= __ANDROID_API_L__
float strtof(const char*, char**) __INTRODUCED_IN(21);
double atof(const char*) __attribute_pure__ __INTRODUCED_IN(21);
int abs(int) __attribute_const__ __INTRODUCED_IN(21);