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

Author Topic: Unresolved External symbol (followed tutoriall)  (Read 890 times)

0 Members and 1 Guest are viewing this topic.

pr1nceray

  • Newbie
  • *
  • Posts: 2
    • View Profile
Unresolved External symbol (followed tutoriall)
« on: February 26, 2024, 02:29:49 am »
Hello,
I am trying to make an sfml program; this isn't my first project with sfml and vs2022; one of my projects compiles, the other has a linker error. I have ran through my project settings, yet i cannot find a difference.

I followed the tutorial; using sfml 2.6.0.
included are my project property settings.

https://imgur.com/a/VJQYlwW

I even tried making a new project that wasn't using cuda (so i could change additional include directories, which isnt there under cuda projects) and following the steps, yet It still fails, with the exact same errors.

plz help :(

edit : In my second project mentioned above, i used sfml-main.lib; this was incorrect, and now my second project works with sfml. rectifying this issue with my main project, i now get cuda errors.
edit2 : had to past all the .bin files into my project with my files, seems to compile now.
« Last Edit: February 26, 2024, 03:37:17 am by pr1nceray »

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11030
    • View Profile
    • development blog
    • Email
Re: Unresolved External symbol (followed tutoriall)
« Reply #1 on: February 26, 2024, 08:48:49 am »
The error message shown would mean that you didn't define SFML_STATIC while linking SFML statically. You can see that because it was trying to resolve _declspec(dllimport) symbols, which are symbols from a DLL and thus not from a static library.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

pr1nceray

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: Unresolved External symbol (followed tutoriall)
« Reply #2 on: February 26, 2024, 08:56:45 pm »
Ya, that was the issue; added sfml_static under preprocessor in Cuda/C++; i was trying to dynamically link it at the time, so i dont know why it was statically linking

 

anything