VERSION=\"1.2.1\"
ifeq ($(OS),Darwin)
-CONFIG_CFLAGS=-DHAVE_INTTYPES_H -DHAVE_ICONV -DHAVE_LANGINFO_CODESET -DFLAC__HAS_OGG -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DFLAC__SYS_DARWIN -DWORDS_BIGENDIAN
+CONFIG_CFLAGS=-DHAVE_STDINT_H -DHAVE_ICONV -DHAVE_LANGINFO_CODESET -DFLAC__HAS_OGG -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -DFLAC__SYS_DARWIN -DWORDS_BIGENDIAN
else
-CONFIG_CFLAGS=-DHAVE_INTTYPES_H -DHAVE_ICONV -DHAVE_LANGINFO_CODESET -DHAVE_SOCKLEN_T -DFLAC__HAS_OGG -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
+CONFIG_CFLAGS=-DHAVE_STDINT_H -DHAVE_ICONV -DHAVE_LANGINFO_CODESET -DHAVE_SOCKLEN_T -DFLAC__HAS_OGG -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
endif
OGG_INCLUDE_DIR=$(HOME)/local/include
<li>
build system:
<ul>
- <li>Fix #includes for gcc 4.3 (<a href="https://sourceforge.net/tracker/index.php?func=detail&aid=1834168&group_id=13478&atid=313478">SF #1834168</a>).</li>
+ <li>Fix #includes for gcc 4.3 (<a href="https://sourceforge.net/tracker2/?func=detail&aid=1834168&group_id=13478&atid=113478">SF #1834168</a>).</li>
+ <li>Fixes for windows builds (<a href="https://sourceforge.net/tracker2/?func=detail&aid=1676822&group_id=13478&atid=113478">SF #1676822</a>).</li>
</ul>
</li>
<li>
flac__utils_printf(stderr, 1, "ERROR: filename too long: %s", option_values.filenames[i]);
return 1;
}
- if(0 == strcmp(option_values.filenames[i], "-")) {
- FLAC__ASSERT(0);
- /* double protection */
- flac__utils_printf(stderr, 1, "internal error\n");
- return 2;
- }
if(0 != (error = grabbag__replaygain_store_to_file_album(outfilename, album_gain, album_peak, option_values.preserve_modtime))) {
flac__utils_printf(stderr, 1, "%s: ERROR writing ReplayGain album tags (%s)\n", outfilename, error);
retval = 1;
}
}
- if(/*@@@@@@why no stdin?*/encode_infile == stdin || option_values.force_to_stdout) {
+ if(option_values.force_to_stdout) {
if(option_values.replay_gain) {
conditional_fclose(encode_infile);
return usage_error("ERROR: --replay-gain cannot be used when encoding to stdout\n");
(void) vfprintf(stream, format, args);
va_end(args);
+
+#ifdef _MSC_VER
+ if(stream == stderr)
+ fflush(stream); /* for some reason stderr is buffered in at least some if not all MSC libs */
+#endif
}
}
#include <stdlib.h> /* for malloc() */
#include <string.h> /* for memcpy(), memset() */
#ifdef _MSC_VER
-#include <winsock.h> /* for ntohl() */
+# include <winsock.h> /* for ntohl() */
+# if _MSC_VER >= 1310
+# include <winsock2.h> /* for ntohl(), sometimes it is not in winsock.h */
+# endif
#elif defined FLAC__SYS_DARWIN
-#include <machine/endian.h> /* for ntohl() */
+# include <machine/endian.h> /* for ntohl() */
#elif defined __MINGW32__
-#include <winsock.h> /* for ntohl() */
+# include <winsock.h> /* for ntohl() */
#else
-#include <netinet/in.h> /* for ntohl() */
+# include <netinet/in.h> /* for ntohl() */
#endif
#include "private/bitmath.h"
#include "private/bitreader.h"
#include <stdlib.h> /* for malloc() */
#include <string.h> /* for memcpy(), memset() */
#ifdef _MSC_VER
-#include <winsock.h> /* for ntohl() */
+# include <winsock.h> /* for ntohl() */
+# if _MSC_VER >= 1310
+# include <winsock2.h> /* for ntohl(), sometimes it is not in winsock.h */
+# endif
#elif defined FLAC__SYS_DARWIN
-#include <machine/endian.h> /* for ntohl() */
+# include <machine/endian.h> /* for ntohl() */
#elif defined __MINGW32__
-#include <winsock.h> /* for ntohl() */
+# include <winsock.h> /* for ntohl() */
#else
-#include <netinet/in.h> /* for ntohl() */
+# include <netinet/in.h> /* for ntohl() */
#endif
#if 0 /* UNUSED */
#include "private/bitmath.h"
# endif
# elif defined(_MSC_VER)
# include <windows.h>
-# undef USE_TRY_CATCH_FLAVOR /* #define this to use the try/catch method for catching illegal opcode exception */
+# define USE_TRY_CATCH_FLAVOR /* sigill_handler flavor resulted in several crash reports on win32 */
# ifdef USE_TRY_CATCH_FLAVOR
# else
LONG CALLBACK sigill_handler_sse_os(EXCEPTION_POINTERS *ep)
#if FLAC__HAS_OGG
FLAC__ogg_encoder_aspect_set_defaults(&encoder->protected_->ogg_encoder_aspect);
#endif
+
+ FLAC__stream_encoder_set_compression_level(encoder, 5);
}
void free_(FLAC__StreamEncoder *encoder)