From c332e7f74ecc754fe77275578f5a3404537e9cb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= Date: Thu, 21 Sep 2006 12:29:49 +0000 Subject: [PATCH] fixed build for R5 : now uses inttypes.h because it's present on R5 also HaikuBuildCompatibily.h exposes INT64_MAX based on limits.h git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18900 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- headers/build/HaikuBuildCompatibility.h | 5 +++++ src/kits/media/Jamfile | 8 -------- src/kits/media/MediaDefs.cpp | 6 +++--- 3 files changed, 8 insertions(+), 11 deletions(-) diff --git a/headers/build/HaikuBuildCompatibility.h b/headers/build/HaikuBuildCompatibility.h index 5b4aeece34..28c7597527 100644 --- a/headers/build/HaikuBuildCompatibility.h +++ b/headers/build/HaikuBuildCompatibility.h @@ -67,5 +67,10 @@ extern float roundf(float value); # define B_BAD_DATA (B_NOT_ALLOWED + 1) #endif +#ifndef INT64_MAX +#include +#define INT64_MAX LONGLONG_MAX +#endif + #endif // HAIKU_BUILD_COMPATIBILITY_H diff --git a/src/kits/media/Jamfile b/src/kits/media/Jamfile index c54c9928db..1e0d60c338 100644 --- a/src/kits/media/Jamfile +++ b/src/kits/media/Jamfile @@ -5,14 +5,6 @@ SetSubDirSupportedPlatformsBeOSCompatible ; if $(TARGET_PLATFORM) != haiku { UseHeaders [ FDirName $(HAIKU_TOP) headers os media ] : true ; # We need the public media headers also when not compiling for Haiku. - UseHeaders [ FDirName $(HAIKU_TOP) headers os ] : true ; - # We need the public headers also when not compiling for Haiku. - UseHeaders [ FDirName $(HAIKU_TOP) headers posix ] : true ; - # We need the public posix headers also when not compiling for Haiku. - UseHeaders [ FDirName $(HAIKU_TOP) headers os support ] : true ; - # We need the public support headers also when not compiling for Haiku. - UseHeaders [ FDirName $(HAIKU_TOP) headers os app ] : true ; - # We need the public app headers also when not compiling for Haiku. } UsePrivateHeaders media shared ; diff --git a/src/kits/media/MediaDefs.cpp b/src/kits/media/MediaDefs.cpp index e95baa81aa..ac6366e69b 100644 --- a/src/kits/media/MediaDefs.cpp +++ b/src/kits/media/MediaDefs.cpp @@ -6,9 +6,9 @@ #include #include #include +#include #include #include -#include #include "MediaMisc.h" #include "debug.h" @@ -725,7 +725,7 @@ media_format::operator=(const media_format &clone) if (meta_data_area < 0) { // whoops, we just lost our meta data meta_data = NULL; - meta_data_size = NULL; + meta_data_size = 0; } } else { meta_data = malloc(meta_data_size); @@ -733,7 +733,7 @@ media_format::operator=(const media_format &clone) memcpy(meta_data, clone.meta_data, meta_data_size); } else { // whoops, we just lost our meta data - meta_data_size = NULL; + meta_data_size = 0; } } }