Help - Search - Members - Calendar
Full Version: libFLAC_static.lib win64
Hydrogenaudio Forums > Lossless Audio Compression > FLAC
rubenvb
Hi all,

I'm not sure this is the place to ask, but here goes...

I need a x64 Windows compile of libFLAC_static. Before you bash on me for wanting a 64-bit codec, please read on as to discover the reason for my unusual request:
I'm trying to get Windows Media Player Tag Support Extender to work with WMP11 64-bit along with the Xiph.org x64 FLAC codec. Then I can manage my music in WMP without fuss (hopefully).
I'm sure it's possible, because there's dll's included in the DShow Xiph codec filter thing. (not quite sure of the right terminology).

What I have tried so far:
Downloaded WMPTSE source from Sourceforge (version 1.2)
Tried to compile the included Tagsupport.sln. Linker errors popped up for functions and classes that seemed to belong to the FLAC library. Then I concluded that the libFLAC_static.lib supplied with WMPTSE was the 32-bit version (because it has been released only for 32-bit WMP) and now I need a 64-bit flac library.

Seeing as I could not find a x64 libflac_static.lib, I thought, hell, it's FOSS for something, and down'ed the flac 1.2.1 source code. I opened up the flac.sln and tried to compile only libFLAC_static.
THe first compiling errors I met were ogg headers which were not included, so I got them in their correct directories and moved on. Not there yet sad.gif
There was an error about some external build tool. I found what it was, "nasmw.exe", so I down'ed that (v2.07, x64 is supported), and copied and renamed the nasm.exe to nasmw.exe in the correct directory. Now it starts compiling and doing its thing, but it gives loads of errors for a x64 target that it doesn't give for win32. I noticed the .asm files have a lot of win32 stuff and win32 built tool options, so I decided it maybe wasn't a good idea to port assembler code to another architecture. So I found this patch: http://osdir.com/ml/comp.audio.compression...5/msg00025.html
which I'm applying manually as the patch.exe from GNUWin won't work (my fault, I know smile.gif)....

If anyone could help me with either a static x64 flac lib + headers or the corrected flac source code that compiles, I'd be ver grateful!
rubenvb
Sorry to be so crappy-mannered in my first HA thread...

but I succesfully compiled the library doing this exactly:

1) set preprocessor definition FLAC__HAS_NASM to FLAC__NO_ASM for the libFLAC_static project
2) set preprocessor definition FLAC__CPU_IA32 to FLAC__CPU_AMD64 (don't know if this is necessary, seemed logical to do smile.gif)
2) apply patch http://osdir.com/ml/comp.audio.compression...5/msg00025.html
3) build, hopefulle succesfully smile.gif
jcoalson
if it's any consolation, I plan on having a win64 build of the next release, whenever I can get to it.
twistedddx
We ran with:
CODE
    unsigned char * t = (unsigned char *)start;
    unsigned char temp;
    int x;
    for (x=0; x<len; x+=4)
    {
        temp = t[0];
        t[0] = t[3];
        t[3] = temp;
        temp = t[1];
        t[1] = t[2];
        t[2] = temp;

        t+=4;
    }

in bitreader.c
rubenvb
Hey, thanks for the answers!

The non-asm code also worked fine (at least to compile, haven't tested anything yet).

@jcoalson: any idea when a next flac release is coming? It's been a while an although 1.2.1 works fine, there are some hiccups to be overcome (like win64 MSVC support, and perhaps an experimental MINGW64 build, although that last one's a lot of work smile.gif)
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.