aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Berger <j.david.berger@gmail.com>2018-03-08 11:25:12 -0700
committerJustin Berger <j.david.berger@gmail.com>2018-03-08 11:25:12 -0700
commitf5022be0b94cbd5b5ead8dc6035551ae1d011db0 (patch)
treea65880494f5a86802f32b403897d0af5a402909c
parent728f6f9e7f0a99aa584e7f35ade387e852b5fa83 (diff)
downloadlibsurvive-f5022be0b94cbd5b5ead8dc6035551ae1d011db0.tar.gz
libsurvive-f5022be0b94cbd5b5ead8dc6035551ae1d011db0.tar.bz2
Updated error message to be more helpful
-rwxr-xr-xsrc/survive.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/survive.c b/src/survive.c
index 4e52637..76bf8e4 100755
--- a/src/survive.c
+++ b/src/survive.c
@@ -96,7 +96,9 @@ static void *button_servicer(void * context)
void survive_verify_FLT_size(uint32_t user_size) {
if(sizeof(FLT) != user_size) {
- fprintf(stderr, "FLT type incompatible; the shared library has FLT size %lu vs user program %u\n", sizeof(FLT), user_size);
+ fprintf(stderr, "FLT type incompatible; the shared library libsurvive has FLT size %lu vs user program %u\n", sizeof(FLT), user_size);
+ fprintf(stderr, "Add '#define FLT %s' before including survive.h or recompile the shared library with the appropriate flag. \n",
+ sizeof(FLT) == sizeof(double) ? "double" : "float");
exit(-1);
}
}