Author Topic: Keep getting "It seems that this project has not been built yet."  (Read 22374 times)

Offline IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Hi,

I have a project which builds a DLL.     Code blocks is setup to run an executable which loads the DLL.

Each time I hit run, a dialog box appears saying "It seems that this project has not been built yet.   Do you want to build it now?".  I click yes, the project builds successfully.

Hit execute again, then a dialog box appears again saying "It seems that this project has not been built yet.   Do you want to build it now?".

How does Code Blocks determine whether the project has already been built?  As I think there maybe a config file marked read only somewhere.

Thanks.
ICB.



« Last Edit: July 20, 2010, 02:47:27 pm by IceColdBeer »

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Keep getting "It seems that this project has not been built yet."
« Reply #1 on: July 20, 2010, 05:20:08 pm »
OS, CB, Gcc versions please?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #2 on: July 20, 2010, 07:50:41 pm »
OS, CB, Gcc versions please?

Hello,

OS = Windows 7 (32 bit)
CB = 10.05
GCC was installed from MinGW 5.6.1
« Last Edit: July 20, 2010, 08:16:32 pm by IceColdBeer »

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Keep getting "It seems that this project has not been built yet."
« Reply #3 on: July 20, 2010, 10:26:01 pm »
GCC was installed from MinGW 5.6.1
Try newer gcc, that one might be broken on vista/7, TDM release of the compiler is pretty good, you can try that one.
Also I think your version is 5.1.6...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #4 on: July 21, 2010, 09:30:13 am »
Yes, typo, I meant MinGW-5.1.6.

Looks like MinGW-5.1.6 is the latest version.

gcc - version 3.4.5 (mingw-vista special r3)
mingw32-make - GNU Make 3.81

I don't think it is a compiller issue as the project compiles and links.  The output DLL is produced successfully.   My question was how CB determines whether the project needs to be built again...

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7588
    • My Best Post
Re: Keep getting "It seems that this project has not been built yet."
« Reply #5 on: July 21, 2010, 02:30:01 pm »
IIRC, That message means it can not find the EXE to run.

Edit: See what "Project" -> "Set Program Arguments" setting are.

Edit2: Please try using "Build" instead of "Build and Run" and does the message still appear?

Tim S.
« Last Edit: July 21, 2010, 02:36:09 pm by stahta01 »
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 IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #6 on: July 21, 2010, 03:37:29 pm »

Edit: See what "Project" -> "Set Program Arguments" setting are.

"This target provides the projects main executable" is not ticked.

If I choose Build and then select Run seperately, the problem still occurs.


Offline IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #7 on: July 21, 2010, 06:27:48 pm »
Nothing is failing as the DLL is generated successfully, what I can't understand is why it wants to keep rebuilding it as no source has been updated.

The question is how Code Blocks determines whether to do a rebuild or not?   If it looks at the date the executable created, then it will older than the source because the project is building a DLL and not an EXE.    Is this a bug in Code Blocks?

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7588
    • My Best Post
Re: Keep getting "It seems that this project has not been built yet."
« Reply #8 on: July 21, 2010, 06:38:15 pm »
User can not be helped by me; deleted posts to save space.
« Last Edit: July 21, 2010, 07:42:35 pm by stahta01 »
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 IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #9 on: July 21, 2010, 06:46:27 pm »


Turning on compiler logging isn't going to help as the build is successful.

I believe this problem is caused because Code Blocks is looking at the EXE creation date instead of the DLL creation date.

My question was how Code Blocks determines whether to do a rebuild?   Please stop replying with turning on full compiler logging, what has it got to do with the compiler?   The compiler doesn't tell Code Blocks whether to rebuild does it !

If you don't know, please don't post back  - Thanks.

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Keep getting "It seems that this project has not been built yet."
« Reply #10 on: July 21, 2010, 08:08:09 pm »
Before the message, you should see: "Checking for existence: ...".

Make sure the dll exists in the place C::B looks for it.

EDIT:
And make sure you have no spaces or special characters in the path and the dll is on the same drive as MinGW.

Or better update your MinGW installation (I suggest TDM's build: http://tdm-gcc.tdragon.net/, or the one provided with C::B 10.5 [TDM MinGW gcc4.4]).
« Last Edit: July 21, 2010, 08:18:15 pm by jens »

Offline IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #11 on: July 22, 2010, 10:53:59 am »
Before the message, you should see: "Checking for existence: ...".

Make sure the dll exists in the place C::B looks for it.

And make sure you have no spaces or special characters in the path and the dll is on the same drive as MinGW.

The DLL name contains no whitespaces or unusual characters.     Putting the DLL on the same drive as MinGW isn't really going to help - but thanks anyway.

Ok, did the following:

1)  Deleted the generated DLL from the previous build.
2)  Build->Clean
3)  Build->Build
4)  ||=== Build finished: 0 errors, 13 warnings ===|
5)  DLL created successfully 22/07/2010 10:43
6)  Go to Build->Run  and:
     "It seems that this project has not been built yet.   Do you want to build it now?"

Or better update your MinGW installation (I suggest TDM's build: http://tdm-gcc.tdragon.net/, or the one provided with C::B 10.5 [TDM MinGW gcc4.4]).

We don't even know if MinGW tools are used to determine whether the rebuild needs to be done, so could be a waste of time upgrading.

 * * * *

Code Blocks is using a GNU makefile to build the project and displays the following in the build log box when building:
"Using makefile: makefile"

This means I can also build the project outside of Code Blocks by just calling "mingw32-make.exe".

My question was how Code Blocks determines whether to do a rebuild?     Does it use the MinGW tools to check or does it just check the date of the EXE or DLL internally without MinGW?      I don't believe CB is using "mingw32-make.exe" to determine whether to do a rebuild, as it would have to wait for the string "is up to date" from mingw32-make.exe and this would mean starting the build in order to deteremine whether the build was upto date or not.
« Last Edit: July 22, 2010, 11:28:41 am by IceColdBeer »

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Keep getting "It seems that this project has not been built yet."
« Reply #12 on: July 22, 2010, 12:20:12 pm »
Sorry to say, but it seems you don't really want help.
Before the message, you should see: "Checking for existence: ...".

Make sure the dll exists in the place C::B looks for it.
The message "Checking for existence:" is quite clear and tells you how (and where) C::B looks for the dll.
If it is not there, please fix your configuration in the projects properties for the appropriate targets ("Output filename" is where you have to look at).

You did not write that you use a custom makefile until your last post, but this is really important, a makefile does things C::B can not know about, because it bypasses C::B's own build-system.

In my previous post I told you what to do, but it seems you know it better.

We don't even know if MinGW tools are used to determine whether the rebuild needs to be done, so could be a waste of time upgrading.
Yes, in custom makefile they are used, but theat's not the cause for your problem.

It's a waste of our time, if users who want help do not give important information as it should be done automatically if anyone asks for help (not only here, but in any help forum or any other situation).


Offline IceColdBeer

  • Multiple posting newcomer
  • *
  • Posts: 10
Re: Keep getting "It seems that this project has not been built yet."
« Reply #13 on: July 22, 2010, 12:47:12 pm »
Yes, I should have mentioned that I was using my own makefile (sorry), but the original question was

How does Code Blocks determine whether the project has already been built?

I've had a list of responses asking to turn on compiler logging and upgrade the MinGW tools etc.  which has side tracked this thread.

Sorry to say, but it seems you don't really want help.

I only wanted to know how Code Blocks determines whether the project has already been built?    Once I know that, I can look into the problem.   I thought I'd be taking to a developer on CB on this thread who could give me a quick answer.

I don't think it something anyone would know unless they'd written that part of the software in CB.

It looks like I'm going to have to live with the message ("It seems that this project has not been built yet.   Do you want to build it now?"), but it's no big deal and can just say no.    

I think Code Blocks is a great piece of Software Engineering :)
« Last Edit: July 22, 2010, 12:55:33 pm by IceColdBeer »

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Keep getting "It seems that this project has not been built yet."
« Reply #14 on: July 22, 2010, 12:55:46 pm »
I thought I'd be taking to a developer on CB on this thread who could give me a quick answer.

I am a developer of C::B and you still did not do what I told you (and I gave you the answers you asked for):
[...]
Before the message, you should see: "Checking for existence: ...".

Make sure the dll exists in the place C::B looks for it.
The message "Checking for existence:" is quite clear and tells you how (and where) C::B looks for the dll.
If it is not there, please fix your configuration in the projects properties for the appropriate targets ("Output filename" is where you have to look at).


[...]
We don't even know if MinGW tools are used to determine whether the rebuild needs to be done, so could be a waste of time upgrading.
Yes, in custom makefile they are used, but theat's not the cause for your problem.
[...]