Update C sources for Android and noaudio
This commit is contained in:
parent
0677b256f1
commit
32e2cc26d6
2 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,6 @@
|
||||||
|
//go:build !noaudio
|
||||||
|
// +build !noaudio
|
||||||
|
|
||||||
/**********************************************************************************************
|
/**********************************************************************************************
|
||||||
*
|
*
|
||||||
* raudio v1.1 - A simple and easy-to-use audio library based on miniaudio
|
* raudio v1.1 - A simple and easy-to-use audio library based on miniaudio
|
||||||
|
|
|
@ -709,15 +709,17 @@ const char *TextFormat(const char *text, ...); // Formatting of text with
|
||||||
#if defined(PLATFORM_ANDROID)
|
#if defined(PLATFORM_ANDROID)
|
||||||
// To allow easier porting to android, we allow the user to define a
|
// To allow easier porting to android, we allow the user to define a
|
||||||
// main function which we call from android_main, defined by ourselves
|
// main function which we call from android_main, defined by ourselves
|
||||||
extern int main(int argc, char *argv[]);
|
//extern int main(int argc, char *argv[]);
|
||||||
|
extern void android_run();
|
||||||
|
|
||||||
void android_main(struct android_app *app)
|
void android_main(struct android_app *app)
|
||||||
{
|
{
|
||||||
char arg0[] = "raylib"; // NOTE: argv[] are mutable
|
char arg0[] = "raylib"; // NOTE: argv[] are mutable
|
||||||
CORE.Android.app = app;
|
CORE.Android.app = app;
|
||||||
|
|
||||||
|
(void)android_run();
|
||||||
// NOTE: Return codes != 0 are skipped
|
// NOTE: Return codes != 0 are skipped
|
||||||
(void)main(1, (char *[]) { arg0, NULL });
|
//(void)main(1, (char *[]) { arg0, NULL });
|
||||||
}
|
}
|
||||||
|
|
||||||
// NOTE: Add this to header (if apps really need it)
|
// NOTE: Add this to header (if apps really need it)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue