News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

Unable to build multiple files project. Checking for existence......

Started by kuasimikua, October 21, 2020, 06:34:49 AM

Previous topic - Next topic

kuasimikua

Hi all, basically I am able to build my multiple file project but when I try to run it in codeblocks it says that It seems the project has not been built yet, do you want to build it now. If i click yes, t he same prompt just keeps reappearing. Here is the build log.

-------------- Build: Debug in C15P3 (compiler: GNU GCC Compiler)---------------

Linking stage skipped (build target has no object files to link)
Nothing to be done (all items are up-to-date).


-------------- Run: Debug in C15P3 (compiler: GNU GCC Compiler)---------------

Checking for existence: C:\Users\seng\Desktop\C Projects\C15P3\bin\Debug\C15P3.exe


However, using command prompt to run the makefile and run the .exe file created works. I have tried googling around and added my C projects folder to the exclusions for my antivirus but the problem still exists. Any help would be greatly appreciated, am new to C and learning it using KNKING's book. :)

stahta01

http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

C:\Users\seng\Desktop\C Projects\C15P3\bin\Debug\C15P3.exe

I suggest only using ASCII without any spaces in the path.

So, I would suggest renaming "C Projects" to  "C_Projects".

Some compilers has issues with spaces in the path.

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

kuasimikua

Quote from: stahta01 on October 21, 2020, 08:40:51 AM
http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

C:\Users\seng\Desktop\C Projects\C15P3\bin\Debug\C15P3.exe

I suggest only using ASCII without any spaces in the path.

So, I would suggest renaming "C Projects" to  "C_Projects".

Some compilers has issues with spaces in the path.

Tim S.

Hi Sir, thank you for the help and response. I have changed the folder name accordingly but problem still persists.

I am running Code::Blocks version 20.03 The compiler I use is GNU GCC Compiler. gcc (MinGW.org GCC Build-20200227-1) 9.2.0

Description of problem: Mentioned in 1st post

Build log:


-------------- Clean: Debug in CC15P3 (compiler: GNU GCC Compiler)---------------

Cleaned "CC15P3 - Debug"

-------------- Build: Debug in CC15P3 (compiler: GNU GCC Compiler)---------------

Linking stage skipped (build target has no object files to link)
Nothing to be done (all items are up-to-date).




Crash report: NIL, just repeatedly prompts me that project has not been built. Attached is an image of the prompt.

I have already tried ...
-Restarting computer and codeblocks
-Excluding folder from anti virus scans
... but none of them worked.

BlueHazzard

Check if you have added your file to the compiling target:
Project->Properties->Build targets->Select a build target on the left->Check if all files have a check mark in "Build target files"
the same for the second target on the left

kuasimikua

Quote from: BlueHazzard on October 21, 2020, 04:34:21 PM
Check if you have added your file to the compiling target:
Project->Properties->Build targets->Select a build target on the left->Check if all files have a check mark in "Build target files"
the same for the second target on the left

Omg thank you sir! All the files were apparently unchecked and now after ur advice it works. Thank you for the help and bless you :)))

Also, do you mind me asking how does what I did fix the problem? thank yoU!!!

BlueHazzard

Codeblocks manages the build in targets (for example called release and debug)... Each target has a collection of files to compiler and link together. At the end of each target there is a binary file (or for virtual targets, other targets)
So it is possible to build multiple exe or libraries within one codeblocks project. A.cpp --> A.exe, B.cc -->B.dll

When you add (or create) new files to the project, codeblocks ask to what targets it should add your files. By default all targets are selected, you probably have deselected all targets, so you had to do it by hand a second time...

Edit: you can look here: http://wiki.codeblocks.org/index.php?title=The_build_process_of_Code::Blocks