<DIV>I have deleted "elseif(UNIX)" branch and it has been built successfully in Cygwin, thanks!</DIV>
<DIV> </DIV>
<DIV>if(X64)<BR> set(ASM_FLAGS "-DARCH_X86_64=1 -m amd64 -DPIC")<BR> if(APPLE)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f macho64 -DPREFIX")<BR> elseif(UNIX)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f elf64")<BR> else()<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f win64")<BR> endif()<BR>else()<BR> set(ASM_FLAGS -DARCH_X86_64=0)<BR> if(APPLE)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f macho")<BR> else()<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f win32 -DPREFIX")<BR> endif()<BR>endif()</DIV>
<DIV> </DIV>
<DIV><BR><FONT style="BACKGROUND-COLOR: #cccccc">On Tue, Nov 12, 2013 at 9:54 PM, chen <</FONT><A href="https://mailman.videolan.org/listinfo/x265-devel"><FONT style="BACKGROUND-COLOR: #cccccc">chenm003 at 163.com</FONT></A><FONT style="BACKGROUND-COLOR: #cccccc">> wrote:<BR><BR>></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><I><FONT style="BACKGROUND-COLOR: #cccccc"> On Mon, Nov 11, 2013 at 8:51 PM, <</FONT><A href="https://mailman.videolan.org/listinfo/x265-devel"><FONT style="BACKGROUND-COLOR: #cccccc">idxa at sina.com</FONT></A><FONT style="BACKGROUND-COLOR: #cccccc">> wrote:<BR></FONT></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> Hi,<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> I have built x265 in cygwin using the following step,<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> 1. cd x265/build/linux<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> 2. ./make-Makefiles.bash<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> 3. make<BR></I>>></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> it shows:<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> Cannot export x265_cpu_cpuid: symbol not defined<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> Cannot export x265_cpu_cpuid_test: symbol not defined<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> Cannot export x265_cpu_emms: symbol not defined<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> ...<BR></I>>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> My question is how to modify to let x265 support cygwin?<BR></I>>></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> We primarily support MinGW for GCC on Windows, but in all likely-hood<BR></I>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> cygwin could be made to work.<BR></I>></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> Can you send me the full build log, particularly the cmake portion? For<BR></I>></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> whatever reason cpu-a.asm isn't being linked into the static lib.<BR></I>></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><FONT style="BACKGROUND-COLOR: #cccccc"><I> Seems ABI problem, he use GCC makefile and Cygwin+Yasm use difference ABI</DIV>
</I>></FONT><I><BR></I><FONT style="BACKGROUND-COLOR: #cccccc">></FONT><I><BR></I><BR><FONT style="BACKGROUND-COLOR: #cccccc">good point. This might be a yasm command line flag issue, our cmake file<BR>has:<BR>if(X64)<BR> set(ASM_FLAGS "-DARCH_X86_64=1 -m amd64 -DPIC")<BR> if(APPLE)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f macho64 -DPREFIX")<BR> elseif(UNIX)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f elf64")<BR> else()<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f win64")<BR> endif()<BR>else()<BR> set(ASM_FLAGS -DARCH_X86_64=0)<BR> if(APPLE)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f macho")<BR> elseif(UNIX)<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f elf32")<BR> else()<BR> set(CMAKE_ASM${ASM_DIALECT}_COMPILER_ARG1 "-f win32 -DPREFIX")<BR> endif()<BR>endif()<BR><BR>I presume cygwin takes the UNIX path; but does elf64/elf32 link with cygwin<BR>gcc compiled C++ code? I'm afraid it's been several years since I've used<BR>cygwin. Msys has been a much saner environment for so long.<BR></FONT>