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

Author Topic: Errors On Compilation  (Read 16828 times)

0 Members and 1 Guest are viewing this topic.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Errors On Compilation
« Reply #15 on: June 15, 2012, 07:58:55 am »
Quote
I did. Whatever's broken is a default
You shouldn't blindly rely on SFML tutorials. I wrote them so that the forum is not spammed with beginners questions, but the truth is that one should know its tools before using a library. There are probably more complete tutorials around the internet that would help you understand Visual Studio.
Laurent Gomila - SFML developer

NameUser

  • Newbie
  • *
  • Posts: 30
    • View Profile
Re: Errors On Compilation
« Reply #16 on: June 15, 2012, 04:12:22 pm »
Quote
I did. Whatever's broken is a default
You shouldn't blindly rely on SFML tutorials. I wrote them so that the forum is not spammed with beginners questions, but the truth is that one should know its tools before using a library. There are probably more complete tutorials around the internet that would help you understand Visual Studio.

You have to understand I'm getting conflicting directions now. Gonna take yours though seeing as you made the bloody thing.

I've used VS a fair bit, I've just never had to worry about changing the bit version before, because I previously had a 32 bit system.

If you could please just tell me how to fix this, I really am itching to get back to learning and practicing.
« Last Edit: June 15, 2012, 04:20:51 pm by NameUser »

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Errors On Compilation
« Reply #17 on: June 15, 2012, 04:43:36 pm »
You should start by telling us what you did. At the beginning of this thread you had linker errors and then suddenly it's a platform issue.

--> how did you solve the linker errors, and what did you do to trigger this 64-bits error?
Laurent Gomila - SFML developer

NameUser

  • Newbie
  • *
  • Posts: 30
    • View Profile
Re: Errors On Compilation
« Reply #18 on: June 15, 2012, 04:57:59 pm »
I started a new project and followed it strictly off of that tutorial exploiter linked. It was pretty similar to what I did the first time. I can tell there were a few differences but I don't remember exactly what.

I got the platform errors when I finished following that and plugged in the code to test it that the tutorial gives.

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11032
    • View Profile
    • development blog
    • Email
Re: Errors On Compilation
« Reply #19 on: June 16, 2012, 10:45:26 am »
Mind informing me how I do this?

I guess some googling would have answered you that question but... ::)

On the top of VS there should be a dropdown box with "Debug" (or "Release") written, next to that one there's another dropdown box with "x64"  (or "Win32") written in it. If there's "x64" then you're compiling for 64bit CPUs and you can change that by selecting "Configuration-Manager" (or similar) in the dropdown box, then a dialogbox will open, there you choose from the top right dropdown box <New...> and on the next window choose in the uppper dropdown box "Win32".
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

NameUser

  • Newbie
  • *
  • Posts: 30
    • View Profile
Re: Errors On Compilation
« Reply #20 on: June 16, 2012, 05:52:01 pm »
I tried googling first, it's too vague of a search. I get a million results about visual studio and bit types, but none really all that helpful.

Also, that's not the problem. It's already Win32. The problem is that the "module machine type" is x64. How would I change THAT?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11032
    • View Profile
    • development blog
    • Email
Re: Errors On Compilation
« Reply #21 on: June 16, 2012, 06:25:15 pm »
Also, that's not the problem. It's already Win32. The problem is that the "module machine type" is x64. How would I change THAT?

Project->Settings->Linker->Advanced->Target machine or similar. ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

NameUser

  • Newbie
  • *
  • Posts: 30
    • View Profile
Re: Errors On Compilation
« Reply #22 on: June 16, 2012, 07:50:03 pm »
Already set to x86 :|

Edit: Now here's something curious. Setting it to x64 causes the error to reverse.

Debug\main.obj : fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'

How does that make any sense at all?
« Last Edit: June 16, 2012, 07:53:33 pm by NameUser »

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Errors On Compilation
« Reply #23 on: June 16, 2012, 08:11:15 pm »
Don't forget to "rebuild all" after such modifications.
Laurent Gomila - SFML developer

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11032
    • View Profile
    • development blog
    • Email
Re: Errors On Compilation
« Reply #24 on: June 16, 2012, 09:05:12 pm »
What Laurent said and you're sure you created a completly new project and didn't add stuff to the old one?

Quote
Debug\main.obj : fatal error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'
This makes actually sense since your main.obj got compiled nonetheless as x86 and now confilicts with the target machine x64.
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

NameUser

  • Newbie
  • *
  • Posts: 30
    • View Profile
Re: Errors On Compilation
« Reply #25 on: June 16, 2012, 09:36:39 pm »
A friend helped me out with this. The error was in the compilation of SFML. I accidently compiled it as 64-bit, which led to this large variety of issues.


Regardless, thanks for all the help. One final question, could anyone link me to a safe download of MSVCR100.dll?

Thanks. :P

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: Errors On Compilation
« Reply #26 on: June 16, 2012, 09:57:50 pm »
Did you ever tell us that you recompiled SFML yourself? We even spoke about the 32-bit precompiled RC, and you said nothing. I think we wasted many posts in this thread... >:(

Quote
One final question, could anyone link me to a safe download of MSVCR100.dll?
Here is what your users are supposed to install:
http://www.microsoft.com/en-us/download/details.aspx?id=5555
Laurent Gomila - SFML developer

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11032
    • View Profile
    • development blog
    • Email
Re: Errors On Compilation
« Reply #27 on: June 16, 2012, 10:28:43 pm »
A friend helped me out with this. The error was in the compilation of SFML. I accidently compiled it as 64-bit, which led to this large variety of issues.

Did you ever tell us that you recompiled SFML yourself? We even spoke about the 32-bit precompiled RC, and you said nothing. I think we wasted many posts in this thread... >:(

Such things really piss me off sometimes.  >:(
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

NameUser

  • Newbie
  • *
  • Posts: 30
    • View Profile
Re: Errors On Compilation
« Reply #28 on: June 16, 2012, 10:50:43 pm »
Did you ever tell us that you recompiled SFML yourself? We even spoke about the 32-bit precompiled RC, and you said nothing. I think we wasted many posts in this thread... >:(

Quote
One final question, could anyone link me to a safe download of MSVCR100.dll?
Here is what your users are supposed to install:
http://www.microsoft.com/en-us/download/details.aspx?id=5555
Frankly I never even realized there was a precompiled version.  :-\

When you spoke of a 32-Bit RC I assumed it was expected that I recompiled. Apologies.

Quote
One final question, could anyone link me to a safe download of MSVCR100.dll?
Here is what your users are supposed to install:
http://www.microsoft.com/en-us/download/details.aspx?id=5555
That's not why I asked. I get an error whenever I try and test a program due to lack of that. Attempting to install that offers to repair or remove it. Repair doesn't help at all. Which brings me to my original question.

And now I need MSVCR100D.dll actually.


EDIT:

Through a lot of pain and suffering, I finally have it working. Thanks for all the help. This can be closed now.
« Last Edit: June 16, 2012, 11:48:51 pm by NameUser »