SFML community forums

General => General discussions => Topic started by: Fierce_Dutch on November 28, 2010, 11:57:29 pm

Title: Laurent I need Help with My own LIB
Post by: Fierce_Dutch on November 28, 2010, 11:57:29 pm
Hey, I have tried to create my own lib that uses sfml-graphics-s-d.lib and the  others and when I build it, it builds fine. But when I start making a new game with my lib then it gives me a whole list of error's. BTW I inlcude sfml-graphics-s-d.lib in my new game too so I think there is conflict there...

Here are my error's

First-chance exception at 0x7705de24 in Pikin Sticks v0.1.exe: 0xC0000005: Access violation reading location 0x035b73ef.
First-chance exception at 0x7705de24 in Pikin Sticks v0.1.exe: 0xC0000005: Access violation reading location 0x035b73ef.
First-chance exception at 0x7708598e in Pikin Sticks v0.1.exe: 0xC0000005: Access violation reading location 0xfeeefef6.
Unhandled exception at 0x7708598e in Pikin Sticks v0.1.exe: 0xC0000005: Access violation reading location 0xfeeefef6.
First-chance exception at 0x7708598e in Pikin Sticks v0.1.exe: 0xC0000005: Access violation reading location 0xfeeefef6.
Unhandled exception at 0x7708598e in Pikin Sticks v0.1.exe: 0xC0000005: Access violation reading location 0xfeeefef6.


I experimented with a whole bunch of stuff in the project setting and got it too work but now I get this error..
Title: Laurent I need Help with My own LIB
Post by: Laurent on November 29, 2010, 07:59:49 am
It seems like you messed up your linker settings (most likely the CRT). The first errors make me think that you also compile both projects using different compiler (debugging) options.
Title: Laurent I need Help with My own LIB
Post by: Fierce_Dutch on November 30, 2010, 12:08:49 am
Quote from: "Laurent"
It seems like you messed up your linker settings (most likely the CRT). The first errors make me think that you also compile both projects using different compiler (debugging) options.


Ok so what does that mean? I mean should i go into the linker setting and change the options to /ML for single threaded library? And /MLd for dynamic single threaded library? Also what do you mean debugger options?
Title: Laurent I need Help with My own LIB
Post by: ratzlaff on November 30, 2010, 01:43:37 am
Your project needs to use the same /MD settings as the SFML you are linking against.
Title: Laurent I need Help with My own LIB
Post by: Fierce_Dutch on November 30, 2010, 06:06:19 am
Quote from: "ratzlaff"
Your project needs to use the same /MD settings as the SFML you are linking against.


I changed my lib to /MD and my Game to /MD and it still didnt work...
Title: Laurent I need Help with My own LIB
Post by: Laurent on November 30, 2010, 08:01:26 am
You should start a new project from scratch (or use one of the provided samples), and it should work. Then compare with your project and see what differences there are in the options.
Title: Laurent I need Help with My own LIB
Post by: Fierce_Dutch on November 30, 2010, 04:57:50 pm
Quote from: "Laurent"
You should start a new project from scratch (or use one of the provided samples), and it should work. Then compare with your project and see what differences there are in the options.


Like compare your libs with my libs in the project of those libs?
Title: Laurent I need Help with My own LIB
Post by: Fierce_Dutch on December 01, 2010, 01:18:57 am
I edited the top code now... Help
Title: Laurent I need Help with My own LIB
Post by: Laurent on December 01, 2010, 08:00:17 am
This is confusing, you should just have posted the new errors in a new message, and explain what you did/what's new now.

Anyway. 0xfeeefeee is freed memory, and that's all I can tell you without seeing your code. You should also try to use the debugger.
Title: Laurent I need Help with My own LIB
Post by: Fierce_Dutch on December 01, 2010, 04:21:43 pm
Quote from: "Laurent"
This is confusing, you should just have posted the new errors in a new message, and explain what you did/what's new now.

Anyway. 0xfeeefeee is freed memory, and that's all I can tell you without seeing your code. You should also try to use the debugger.


Ok is there something wrong with my code you think or something wrong with my porject settings? because if I change incremental to yes it gives me lib errors and if i change nodefaultlibs then i also get error's so i turne both those off and then the console pulled up and this appeared. the window flashed.