From 33b20e5c20b0bbac5db9d8022ee5499b8cb95b5c Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 17 Jan 2012 02:13:19 +0000 Subject: Support compilation as C++ under MSVC++, git-svn-id: http://svn.drobilla.net/lad/trunk/lilv@3955 a436a847-0d15-0410-975c-d299462d15a1 --- utils/lv2info.c | 11 ++++++++--- utils/lv2ls.c | 1 - 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'utils') diff --git a/utils/lv2info.c b/utils/lv2info.c index 162a12b..d3a2ade 100644 --- a/utils/lv2info.c +++ b/utils/lv2info.c @@ -14,6 +14,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ +#include #include #include #include @@ -23,6 +24,10 @@ #include "lilv-config.h" +#ifdef _MSC_VER +# define isnan _isnan +#endif + LilvNode* applies_to_pred = NULL; LilvNode* control_class = NULL; LilvNode* event_class = NULL; @@ -307,9 +312,9 @@ print_plugin(LilvWorld* world, /* Ports */ const uint32_t num_ports = lilv_plugin_get_num_ports(p); - float* mins = calloc(num_ports, sizeof(float)); - float* maxes = calloc(num_ports, sizeof(float)); - float* defaults = calloc(num_ports, sizeof(float)); + float* mins = (float*)calloc(num_ports, sizeof(float)); + float* maxes = (float*)calloc(num_ports, sizeof(float)); + float* defaults = (float*)calloc(num_ports, sizeof(float)); lilv_plugin_get_port_ranges_float(p, mins, maxes, defaults); for (uint32_t i = 0; i < num_ports; ++i) diff --git a/utils/lv2ls.c b/utils/lv2ls.c index 5432f37..3ccbcc6 100644 --- a/utils/lv2ls.c +++ b/utils/lv2ls.c @@ -14,7 +14,6 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include #include #include -- cgit v1.2.1