$NetBSD: patch-ai,v 1.1 2004/11/16 12:05:54 sketch Exp $ --- ./src/libFLAC++/file_encoder.cpp.orig 2004-11-15 18:20:18.800446000 +0000 +++ ./src/libFLAC++/file_encoder.cpp 2004-11-15 18:26:18.841164000 +0000 @@ -168,7 +168,7 @@ bool File::set_metadata(FLAC::Metadata::Prototype **metadata, unsigned num_blocks) { FLAC__ASSERT(is_valid()); -#ifdef _MSC_VER +#if (defined _MSC_VER) || (defined __SUNPRO_CC) // MSVC++ can't handle: // ::FLAC__StreamMetadata *m[num_blocks]; // so we do this ugly workaround @@ -180,7 +180,7 @@ // we can get away with this since we know the encoder will only correct the is_last flags m[i] = const_cast< ::FLAC__StreamMetadata*>((::FLAC__StreamMetadata*)metadata[i]); } -#ifdef _MSC_VER +#if (defined _MSC_VER) || (defined __SUNPRO_CC) // complete the hack const bool ok = (bool)::FLAC__file_encoder_set_metadata(encoder_, m, num_blocks); delete [] m; @@ -368,5 +368,5 @@ instance->progress_callback(bytes_written, samples_written, frames_written, total_frames_estimate); } - }; + } };