Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PhyML Compiling Error on Windows (MSYS2) #167

Open
amduffy opened this issue May 18, 2022 · 0 comments
Open

PhyML Compiling Error on Windows (MSYS2) #167

amduffy opened this issue May 18, 2022 · 0 comments

Comments

@amduffy
Copy link

amduffy commented May 18, 2022

Hello,
I've been trying to compile a Windows executable from the Spring 2022 release, but I keep running into undefined reference to 'WinMain@16' errors when running make. I've tried this through both through MSYS2 on a Windows 10 machine and while trying to cross-compile with mingw on an Ubuntu 20.04.4 machine with the same result.

My apologies if there's a common fix to this - I'm not experienced at all with C compilers.

Details of my system setup and the error are below, while console output from autogen, configure, and make are attached

Thank you for your help!

Setup

Windows 10, MSYS2 fresh install (msys2-x86_64-20220503)

Installed packages:

  • base-devel
  • mingw-w64-i686-toolchain
  • autoconf-wrapper
  • automake-wrapper

Attempting to compile phyml-3.3.20220408 (Spring 2022 release) in MSYS2 MINGW x86

Error from make:

i686-w64-mingw32-gcc  -std=c99 -O3 -fomit-frame-pointer -funroll-loops -Wall -Winline -finline -march=native   -o phyml.exe   -lm
C:/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/11.3.0/../../../../i686-w64-mingw32/bin/ld.exe: C:/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/11.3.0/../../../../lib/libmingw32.a(lib32_libmingw32_a-crt0_c.o): in function `main':
C:/M/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/crt/crt0_c.c:18: undefined reference to `WinMain@16'
collect2.exe: error: ld returned 1 exit status
make[2]: *** [Makefile:1134: phyml.exe] Error 1
make[2]: Leaving directory '/c/users/duffy/downloads/phyml-3.3.20220408/src'
make[1]: *** [Makefile:365: all-recursive] Error 1
make[1]: Leaving directory '/c/users/duffy/downloads/phyml-3.3.20220408'
make: *** [Makefile:306: all] Error 2

configure-log.log
autogen-log.log
make-log.log

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant