Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Trying to build with DEV-C++, getting linked errors  (Read 1757 times)

0 Members and 1 Guest are viewing this topic.

m1ndas5

  • Newbie
  • *
  • Posts: 2
    • View Profile
Trying to build with DEV-C++, getting linked errors
« on: January 19, 2020, 12:11:58 am »
Greetings,

I'm trying to build / launch some games found on the web with DEV-C++ IDE.

I have:
- Installed TDM GCC 5.1.0 (verified against simple programs).
- Configured the include path: -I"C:\SFML-2.5.1\include"
- Configured the library path: -L"C:\SFML-2.5.1\lib"
- Added the linked library switches:

Quote
- C++ Compiler: C:\TDM-GCC-64\bin\g++.exe
- Command: g++.exe "C:\Users\darba\Desktop\Other Projects\16_Games\01 Tetris\main.cpp" -o "C:\Users\darba\Desktop\Other Projects\16_Games\01 Tetris\main.exe"  -I"C:\SFML-2.5.1\include" -I"C:\TDM-GCC-64\include" -I"C:\TDM-GCC-64\x86_64-w64-mingw32\include" -I"C:\TDM-GCC-64\lib\gcc\x86_64-w64-mingw32\5.1.0\include" -I"C:\TDM-GCC-64\lib\gcc\x86_64-w64-mingw32\5.1.0\include\c++" -L"C:\SFML-2.5.1\lib" -L"C:\TDM-GCC-64\lib" -L"C:\TDM-GCC-64\x86_64-w64-mingw32\lib" -l sfml-graphics -l sfml-window -l sfml-system
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib/libsfml-graphics.a when searching for -lsfml-graphics
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib\libsfml-graphics.a when searching for -lsfml-graphics
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib/libsfml-graphics.a when searching for -lsfml-graphics
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lsfml-graphics
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib/libsfml-window.a when searching for -lsfml-window
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib\libsfml-window.a when searching for -lsfml-window
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib/libsfml-window.a when searching for -lsfml-window
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lsfml-window
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib/libsfml-system.a when searching for -lsfml-system
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib\libsfml-system.a when searching for -lsfml-system
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: skipping incompatible C:\SFML-2.5.1\lib/libsfml-system.a when searching for -lsfml-system
C:/TDM-GCC-64/bin/../lib/gcc/x86_64-w64-mingw32/5.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lsfml-system
collect2.exe: error: ld returned 1 exit status

m1ndas5

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Trying to build with DEV-C++, getting linked errors
« Reply #1 on: January 19, 2020, 12:14:51 am »
Sorry to bother, seems I needed to install the 32bit compiler since the libraries are 32bit. This can be deleted.

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6286
  • Thor Developer
    • View Profile
    • Bromeon
Re: Trying to build with DEV-C++, getting linked errors
« Reply #2 on: January 19, 2020, 10:34:03 am »
Dev-C++ is a very old IDE, I remember having my first C++ steps with it in the 2000s...

Is there a reason why you don't use a more modern one, e.g. Visual Studio 2019 Community, which is free to use?
It may simplify a lot of configuration/setup on your end, and more people would be able to help you.
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 10801
    • View Profile
    • development blog
    • Email
Re: Trying to build with DEV-C++, getting linked errors
« Reply #3 on: January 20, 2020, 09:41:13 am »
Dev-C++ is a very old IDE, I remember having my first C++ steps with it in the 2000s...
It's been unofficially updated until 2015, I've been using Visual Studio also in the early 2000s, that doesn't mean there haven't been updates. ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

euscar

  • Newbie
  • *
  • Posts: 17
    • View Profile
Re: Trying to build with DEV-C++, getting linked errors
« Reply #4 on: August 28, 2022, 04:45:56 pm »
Hello.

I'm going back to this discussion to say that I'm using Dev-C ++ (Orwell version mentioned above) with SFML 2.4.2 because Dev uses the TDM-GCC 4.9.2 build set and so far everything is ok.

I know there is a new version Dev-C++ 6.3 (which uses TDM-GCC 9.2.0 32 / 64bit) maintained by Embarcadero at this web address https://www.embarcadero.com/free-tools/dev-cpp , but I have never tried it.
Maybe someday I'll do some testing to see if it supports SFML 2.5.1