Author Topic: Unable to build multiple files project. Checking for existence......  (Read 4508 times)

Offline kuasimikua

  • Single posting newcomer
  • *
  • Posts: 4
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. :)

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: Unable to build multiple files project. Checking for existence......
« Reply #1 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

Code
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++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline kuasimikua

  • Single posting newcomer
  • *
  • Posts: 4
Re: Unable to build multiple files project. Checking for existence......
« Reply #2 on: October 21, 2020, 03:41:43 pm »
http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

Code
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:
Code

-------------- 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.

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: Unable to build multiple files project. Checking for existence......
« Reply #3 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

Offline kuasimikua

  • Single posting newcomer
  • *
  • Posts: 4
Re: Unable to build multiple files project. Checking for existence......
« Reply #4 on: October 22, 2020, 03:05:19 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!!!

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: Unable to build multiple files project. Checking for existence......
« Reply #5 on: October 22, 2020, 03:24:43 pm »
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
« Last Edit: October 22, 2020, 03:26:39 pm by BlueHazzard »