Commit d40a6bc6 authored by Erik de Castro Lopo's avatar Erik de Castro Lopo
Browse files

libFLAC: Remove win_utf8_io dependency

Path-from: lvqcl <lvqcl.mail@gmail.com>
parent a5c8e8e1
......@@ -4,27 +4,23 @@ Microsoft Visual Studio Solution File, Format Version 9.00
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "example_c_decode_file", "examples\c\decode\file\example_c_decode_file.vcproj", "{4CEFBD00-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "example_c_encode_file", "examples\c\encode\file\example_c_encode_file.vcproj", "{4CEFBD01-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "example_cpp_decode_file", "examples\cpp\decode\file\example_cpp_decode_file.vcproj", "{4CEFBE00-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBC86-C215-11DB-8314-0800200C9A66} = {4CEFBC86-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "example_cpp_encode_file", "examples\cpp\encode\file\example_cpp_encode_file.vcproj", "{4CEFBE01-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBC86-C215-11DB-8314-0800200C9A66} = {4CEFBC86-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "flac", "src\flac\flac.vcproj", "{4CEFBC7D-C215-11DB-8314-0800200C9A66}"
......@@ -59,29 +55,20 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "grabbag_static", "src\share
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBC89-C215-11DB-8314-0800200C9A66} = {4CEFBC89-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libFLAC_dynamic", "src\libFLAC\libFLAC_dynamic.vcproj", "{4CEFBC83-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libFLAC_static", "src\libFLAC\libFLAC_static.vcproj", "{4CEFBC84-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libFLAC++_dynamic", "src\libFLAC++\libFLAC++_dynamic.vcproj", "{4CEFBC85-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC83-C215-11DB-8314-0800200C9A66} = {4CEFBC83-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libFLAC++_static", "src\libFLAC++\libFLAC++_static.vcproj", "{4CEFBC86-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "metaflac", "src\metaflac\metaflac.vcproj", "{4CEFBC87-C215-11DB-8314-0800200C9A66}"
......@@ -102,7 +89,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_cuesheet", "src\test_g
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBC81-C215-11DB-8314-0800200C9A66} = {4CEFBC81-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_libFLAC", "src\test_libFLAC\test_libFLAC.vcproj", "{4CEFBC8C-C215-11DB-8314-0800200C9A66}"
......@@ -110,7 +96,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_libFLAC", "src\test_li
{4CEFBC8E-C215-11DB-8314-0800200C9A66} = {4CEFBC8E-C215-11DB-8314-0800200C9A66}
{4CEFBC81-C215-11DB-8314-0800200C9A66} = {4CEFBC81-C215-11DB-8314-0800200C9A66}
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_libFLAC++", "src\test_libFLAC++\test_libFLAC++.vcproj", "{4CEFBC8D-C215-11DB-8314-0800200C9A66}"
......@@ -119,26 +104,22 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_libFLAC++", "src\test_
{4CEFBC86-C215-11DB-8314-0800200C9A66} = {4CEFBC86-C215-11DB-8314-0800200C9A66}
{4CEFBC81-C215-11DB-8314-0800200C9A66} = {4CEFBC81-C215-11DB-8314-0800200C9A66}
{4CEFBC8E-C215-11DB-8314-0800200C9A66} = {4CEFBC8E-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_libs_common_static", "src\test_libs_common\test_libs_common_static.vcproj", "{4CEFBC8E-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_picture", "src\test_grabbag\picture\test_picture.vcproj", "{4CEFBC8F-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBC81-C215-11DB-8314-0800200C9A66} = {4CEFBC81-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_seeking", "src\test_seeking\test_seeking.vcproj", "{4CEFBC90-C215-11DB-8314-0800200C9A66}"
ProjectSection(ProjectDependencies) = postProject
{4CEFBC84-C215-11DB-8314-0800200C9A66} = {4CEFBC84-C215-11DB-8314-0800200C9A66}
{4CEFBE02-C215-11DB-8314-0800200C9A66} = {4CEFBE02-C215-11DB-8314-0800200C9A66}
EndProjectSection
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "test_streams", "src\test_streams\test_streams.vcproj", "{4CEFBC91-C215-11DB-8314-0800200C9A66}"
......
......@@ -17,15 +17,14 @@
# distribution.
ifeq ($(findstring Windows,$(OS)),Windows) # "Windows" is provided by GNU Make's internal $(OS)
LIBFLAC_DEPS = share/win_utf8_io
WIN_DEPS = share/win_utf8_io
else
LIBFLAC_DEPS =
WIN_DEPS =
endif
libFLAC: $(LIBFLAC_DEPS)
flac: libFLAC share
flac: libFLAC share $(WIN_DEPS)
libFLAC++: libFLAC
metaflac: libFLAC share
metaflac: libFLAC share $(WIN_DEPS)
plugin_common: libFLAC
plugin_xmms: libFLAC plugin_common
share: libFLAC
......@@ -34,7 +33,7 @@ test_libs_common: libFLAC
test_libFLAC++: libFLAC libFLAC++ test_libs_common
test_libFLAC: libFLAC test_libs_common
test_seeking: libFLAC
test_streams: libFLAC
flacdiff: libFLAC libFLAC++
flactimer: libFLAC libFLAC++
test_streams: share
flacdiff: libFLAC libFLAC++ $(WIN_DEPS)
flactimer:
utils: flacdiff flactimer
......@@ -31,7 +31,7 @@
topdir = .
.PHONY: all doc src examples libFLAC libFLAC++ share/win_utf8_io share plugin_common flac metaflac test_grabbag test_libFLAC test_libFLAC++ test_seeking test_streams flacdiff flactimer
.PHONY: all doc src examples libFLAC libFLAC++ share plugin_common flac metaflac test_grabbag test_libFLAC test_libFLAC++ test_seeking test_streams flacdiff flactimer
all: src examples
DEFAULT_CONFIG = release
......@@ -52,7 +52,7 @@ doc:
src examples:
(cd $@ && $(MAKE) -f Makefile.lite $(CONFIG))
libFLAC libFLAC++ share/win_utf8_io share flac metaflac plugin_common plugin_xmms test_libs_common test_seeking test_streams test_grabbag test_libFLAC test_libFLAC++:
libFLAC libFLAC++ share flac metaflac plugin_common plugin_xmms test_libs_common test_seeking test_streams test_grabbag test_libFLAC test_libFLAC++:
(cd src/$@ && $(MAKE) -f Makefile.lite $(CONFIG))
flacdiff flactimer:
......
......@@ -31,13 +31,9 @@ INCLUDES = -I$(topdir)/include
ifeq ($(OS),Darwin)
EXPLICIT_LIBS = $(libdir)/libFLAC.a $(OGG_EXPLICIT_LIBS) -lm
else
ifeq ($(findstring Windows,$(OS)),Windows)
LIBS = -lFLAC -lwin_utf8_io $(OGG_LIBS) -lm
else
LIBS = -lFLAC $(OGG_LIBS) -lm
endif
endif
SRCS_C = main.c
......
......@@ -172,10 +172,6 @@
<Project>{4cefbc84-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\..\..\..\src\share\win_utf8_io\win_utf8_io_static.vcxproj">
<Project>{4cefbe02-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
......
......@@ -31,13 +31,9 @@ INCLUDES = -I$(topdir)/include
ifeq ($(OS),Darwin)
EXPLICIT_LIBS = $(libdir)/libFLAC.a $(OGG_EXPLICIT_LIBS) -lm
else
ifeq ($(findstring Windows,$(OS)),Windows)
LIBS = -lFLAC -lwin_utf8_io $(OGG_LIBS) -lm
else
LIBS = -lFLAC $(OGG_LIBS) -lm
endif
endif
SRCS_C = main.c
......
......@@ -172,10 +172,6 @@
<Project>{4cefbc84-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\..\..\..\src\share\win_utf8_io\win_utf8_io_static.vcxproj">
<Project>{4cefbe02-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
......
......@@ -31,13 +31,9 @@ INCLUDES = -I$(topdir)/include
ifeq ($(OS),Darwin)
EXPLICIT_LIBS = $(libdir)/libFLAC++.a $(libdir)/libFLAC.a $(OGG_EXPLICIT_LIBS) -lm
else
ifeq ($(findstring Windows,$(OS)),Windows)
LIBS = -lFLAC++ -lFLAC -lwin_utf8_io $(OGG_LIBS) -lm
else
LIBS = -lFLAC++ -lFLAC $(OGG_LIBS) -lm
endif
endif
SRCS_CPP = main.cpp
......
......@@ -176,10 +176,6 @@
<Project>{4cefbc84-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\..\..\..\src\share\win_utf8_io\win_utf8_io_static.vcxproj">
<Project>{4cefbe02-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
......
......@@ -31,13 +31,9 @@ INCLUDES = -I$(topdir)/include
ifeq ($(OS),Darwin)
EXPLICIT_LIBS = $(libdir)/libFLAC++.a $(libdir)/libFLAC.a $(OGG_EXPLICIT_LIBS) -lm
else
ifeq ($(findstring Windows,$(OS)),Windows)
LIBS = -lFLAC++ -lFLAC -lwin_utf8_io $(OGG_LIBS) -lm
else
LIBS = -lFLAC++ -lFLAC $(OGG_LIBS) -lm
endif
endif
SRCS_CPP = main.cpp
......
......@@ -176,10 +176,6 @@
<Project>{4cefbc84-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\..\..\..\src\share\win_utf8_io\win_utf8_io_static.vcxproj">
<Project>{4cefbe02-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
......
......@@ -14,4 +14,5 @@ EXTRA_DIST = \
replaygain_synthesis.h \
safe_str.h \
utf8.h \
win_utf8_io.h
win_utf8_io.h \
windows_unicode_filenames.h
......@@ -146,18 +146,19 @@
#ifdef _WIN32
/* All char* strings are in UTF-8 format. Added to support Unicode files on Windows */
#include "share/win_utf8_io.h"
#include "share/win_utf8_io.h"
#define flac_printf printf_utf8
#define flac_fprintf fprintf_utf8
#define flac_vfprintf vfprintf_utf8
#define flac_fopen fopen_utf8
#define flac_chmod chmod_utf8
#define flac_utime utime_utf8
#define flac_unlink unlink_utf8
#define flac_rename rename_utf8
#define flac_stat _stat64_utf8
#include "share/windows_unicode_filenames.h"
#define flac_fopen flac_internal_fopen_utf8
#define flac_chmod flac_internal_chmod_utf8
#define flac_utime flac_internal_utime_utf8
#define flac_unlink flac_internal_unlink_utf8
#define flac_rename flac_internal_rename_utf8
#define flac_stat flac_internal_stat64_utf8
#else
......
......@@ -34,15 +34,13 @@
#ifndef flac__win_utf8_io_h
#define flac__win_utf8_io_h
#include <stdio.h>
#include <stdarg.h>
#ifdef __cplusplus
extern "C" {
#endif
#include <stdio.h>
#include <sys/stat.h>
#include <stdarg.h>
#include <windows.h>
size_t strlen_utf8(const char *str);
int win_get_console_width(void);
......
......@@ -25,8 +25,8 @@ CPPLIBS_DIRS = libFLAC++ test_libFLAC++
endif
SUBDIRS = \
share \
libFLAC \
share \
flac \
metaflac \
$(XMMS_DIRS) \
......
......@@ -48,6 +48,10 @@ flac_SOURCES = \
utils.h \
vorbiscomment.h
if OS_IS_WINDOWS
win_utf8_lib = $(top_builddir)/src/share/win_utf8_io/libwin_utf8_io.la
endif
flac_LDADD = \
$(top_builddir)/src/share/utf8/libutf8.la \
$(top_builddir)/src/share/grabbag/libgrabbag.la \
......@@ -55,6 +59,7 @@ flac_LDADD = \
$(top_builddir)/src/share/replaygain_analysis/libreplaygain_analysis.la \
$(top_builddir)/src/share/replaygain_synthesis/libreplaygain_synthesis.la \
$(top_builddir)/src/libFLAC/libFLAC.la \
$(win_utf8_lib) \
@LIBICONV@ \
-lm
......
......@@ -43,16 +43,12 @@ endif
ifeq ($(OS),Darwin)
EXPLICIT_LIBS = $(libdir)/libFLAC.a $(OGG_EXPLICIT_LIBS) -lm -lstdc++
else
ifeq ($(findstring Windows,$(OS)),Windows)
LIBS = -lFLAC -lwin_utf8_io $(OGG_LIBS) -lm -lsupc++
else
ifeq ($(OS),FreeBSD)
LIBS = -lFLAC $(OGG_LIBS) -lm -lstdc++
else
LIBS = -lFLAC $(OGG_LIBS) -lm -lsupc++
endif
endif
endif
LIB_NAME = libFLAC++
INCLUDES = -I$(topdir)/include
......
......@@ -173,10 +173,6 @@
<Project>{4cefbc83-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\share\win_utf8_io\win_utf8_io_static.vcxproj">
<Project>{4cefbe02-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
......
......@@ -141,10 +141,6 @@
<Project>{4cefbc84-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
<ProjectReference Include="..\share\win_utf8_io\win_utf8_io_static.vcxproj">
<Project>{4cefbe02-c215-11db-8314-0800200c9a66}</Project>
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
......
......@@ -61,11 +61,7 @@ endif
endif
endif
if OS_IS_WINDOWS
win_utf8_lib = $(top_builddir)/src/share/win_utf8_io/libwin_utf8_io.la
endif
libFLAC_la_LIBADD = $(win_utf8_lib) $(LOCAL_EXTRA_LIBADD) @OGG_LIBS@ -lm
libFLAC_la_LIBADD = $(LOCAL_EXTRA_LIBADD) @OGG_LIBS@ -lm
SUBDIRS = $(ARCH_SUBDIRS) include .
......@@ -86,6 +82,10 @@ EXTRA_DIST = \
libFLAC_static.vcxproj.filters \
libFLAC.m4
if OS_IS_WINDOWS
windows_unicode_compat = windows_unicode_filenames.c
endif
if FLaC__HAS_OGG
extra_ogg_sources = \
ogg_decoder_aspect.c \
......@@ -124,6 +124,7 @@ libFLAC_sources = \
stream_encoder_intrin_avx2.c \
stream_encoder_framing.c \
window.c \
$(windows_unicode_compat) \
$(extra_ogg_sources)
libFLAC_la_SOURCES = $(libFLAC_sources)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment