Code::Blocks Forums

User forums => Help => Topic started by: ____casper____ on April 23, 2022, 12:34:08 pm

Title: Setting up SDL with codeblocks not working!
Post by: ____casper____ on April 23, 2022, 12:34:08 pm
For the last few days ive been trying to setup SDL with codeblocks but i have the same problem everytime, i download the libraries, i extract them to folder, i link them in codeblocks, i type this in tab: other linker options, -lmingw32 -lSDL2main -lSDL2 and when i try to run a program it gives me this error
||=== Build: Debug in SDL testing (compiler: GNU GCC Compiler) ===|
ld.exe||cannot find -lSDL2main|
ld.exe||cannot find -lSDL2|
||error: ld returned 1 exit status|
||=== Build failed: 3 error(s), 0 warning(s) (0 minute(s), 0 second(s)) ===
can somebody help me with this please.
Title: Re: Setting up SDL with codeblocks not working!
Post by: stahta01 on April 23, 2022, 02:06:38 pm
https://wiki.codeblocks.org/index.php/FAQ-Compiling_(general)#Q:_I_would_like_to_compile_a_project_using_some_non-standard_libraries._How_can_I_indicate_to_CodeBlocks_that_these_libraries_and_include_files_exist.3F (https://wiki.codeblocks.org/index.php/FAQ-Compiling_(general)#Q:_I_would_like_to_compile_a_project_using_some_non-standard_libraries._How_can_I_indicate_to_CodeBlocks_that_these_libraries_and_include_files_exist.3F)

Follow the "For your project :" section of the answer.

If you still have problems post a [FULL] build log as described in https://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F (https://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F)

Tim S.