New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

codelite-make build error when workspace build configuration name differs from project's #1629

Closed
kr0st opened this Issue May 3, 2017 · 11 comments

Comments

Projects
None yet
2 participants
@kr0st

kr0st commented May 3, 2017

I have a workspace where one of the build configurations is named "Release". A project in this workspace has configuration that is called "Release-32bit". So, by building workspace configuration "Release" you are building a project configuration "Release-32bit".

The same workspace has configuration called "Release-64bit" and the above mentioned project also has configuration "Release-64bit".

codelite-make has no issues building "Release-64bit" configuration but does not work with "Release-32bit". IDE build is not affected - from IDE I can build all configurations successfully. So it seems that project build configuration name should match workspace build configuration name or build fails.

I was able to workaround the issue by making workspace configuration names same with project configuration names.

Here is the command line that failed before the workaround:

codelite-make -w fplog.workspace -p spipc_test -c Release-32bit -d rebuild -e

----------Cleaning project:[ spipc_test -  ]----------
make[1]: Entering directory '/var/lib/jenkins/workspace/fplog/build_architecture/x86_32/build_target_os/Linux/codelite'
rm -f -r ./Release/
make[1]: Leaving directory '/var/lib/jenkins/workspace/fplog/build_architecture/x86_32/build_target_os/Linux/codelite'
----------Building project:[ spipc_test -  ]----------
/bin/sh: 1: spipc_test.mk: not found
Makefile:4: recipe for target 'All' failed
make: *** [All] Error 127
@kr0st

This comment has been minimized.

Show comment
Hide comment
@kr0st

kr0st May 3, 2017

Forgot to mention: CodeLite version 10.0.3, using it on Linux.

kr0st commented May 3, 2017

Forgot to mention: CodeLite version 10.0.3, using it on Linux.

@eranif

This comment has been minimized.

Show comment
Hide comment
@eranif

eranif May 3, 2017

Owner

If the configuration does not exist, then an error message should have appear, similar to this:

$codelite-make -w LiteEditor.workspace -p CodeLiteIDE -c Linux_debug
[ERROR ] Could not find configuration Linux_debug for project CodeLiteIDE

Another question: CodeLite does not allow you to create configurations with hyphen (-) - did you manually changed the project files?

Owner

eranif commented May 3, 2017

If the configuration does not exist, then an error message should have appear, similar to this:

$codelite-make -w LiteEditor.workspace -p CodeLiteIDE -c Linux_debug
[ERROR ] Could not find configuration Linux_debug for project CodeLiteIDE

Another question: CodeLite does not allow you to create configurations with hyphen (-) - did you manually changed the project files?

@kr0st

This comment has been minimized.

Show comment
Hide comment
@kr0st

kr0st May 3, 2017

Yep, I've seen this message if I use "Release" configuration name that really does not exist for the project but if I specify the existing config that is called "Release-32bit" then I get the described error.

Did not know the rule about hyphens.. most likely you're correct - I've added the configurations by hand, not via the IDE.

So, my bad then and nice IDE btw, thanks!

kr0st commented May 3, 2017

Yep, I've seen this message if I use "Release" configuration name that really does not exist for the project but if I specify the existing config that is called "Release-32bit" then I get the described error.

Did not know the rule about hyphens.. most likely you're correct - I've added the configurations by hand, not via the IDE.

So, my bad then and nice IDE btw, thanks!

@eranif

This comment has been minimized.

Show comment
Hide comment
@eranif

eranif May 3, 2017

Owner

Can you create a minimal example workspace with one project that reproduces this error?
If you can create and attach it, I will probably will be able to debug it

Owner

eranif commented May 3, 2017

Can you create a minimal example workspace with one project that reproduces this error?
If you can create and attach it, I will probably will be able to debug it

@kr0st

This comment has been minimized.

Show comment
Hide comment
@kr0st

kr0st May 3, 2017

Will do that.

kr0st commented May 3, 2017

Will do that.

@kr0st

This comment has been minimized.

Show comment
Hide comment
@kr0st

kr0st May 9, 2017

reproducing_issue.zip

Added zipped workspace. The only thing you might have to change is compiler - I'm on GCC 4.8.

This works fine:

codelite-make -w fplog.workspace -p spipc_test -c Release-64bit -d rebuild -e

This fails to build:

codelite-make -w fplog.workspace -p spipc_test -c Release-32bit -d rebuild -e

However if I rename workspace configurations to match project configurations - there are no more errors.

kr0st commented May 9, 2017

reproducing_issue.zip

Added zipped workspace. The only thing you might have to change is compiler - I'm on GCC 4.8.

This works fine:

codelite-make -w fplog.workspace -p spipc_test -c Release-64bit -d rebuild -e

This fails to build:

codelite-make -w fplog.workspace -p spipc_test -c Release-32bit -d rebuild -e

However if I rename workspace configurations to match project configurations - there are no more errors.

@eranif

This comment has been minimized.

Show comment
Hide comment
@eranif

eranif May 9, 2017

Owner

Thanks, I will try and test this later on today

Owner

eranif commented May 9, 2017

Thanks, I will try and test this later on today

@eranif

This comment has been minimized.

Show comment
Hide comment
@eranif

eranif May 10, 2017

Owner

Ok, thanks for the reproduction zip.
A short summary:
the -c is the Workspace configuration name, not the project configuration name. i.e. in your example, you should have pass here Release and not Release-32bit (since you don't have this configuration in the workspace). So the proper command should be:

codelite-make -w fplog.workspace -p spipc_test -c Release -d rebuild -e

However, even when you pass the correct workspace configuration name (i.e. Release), it still fails - this is because of a bug... which is now fixed.

In general, codelite-make should behave the same as the UI: In the UI you select the workspace configuration from the drop-down list (at the top of the workspace tab) and you hit F7. You don't need to pass the project configuration name (e.g. Release-32bit), since it is already mapped to the workspace configuration (e.g. Release)

I also updated the codelite-make usage text to clearly indicate that you need to pass the workspace configuration name and not the project configuration name.

I hope I am clear, if not, please consider reading this: http://codelite.org/LiteEditor/ConfigurationManager

Owner

eranif commented May 10, 2017

Ok, thanks for the reproduction zip.
A short summary:
the -c is the Workspace configuration name, not the project configuration name. i.e. in your example, you should have pass here Release and not Release-32bit (since you don't have this configuration in the workspace). So the proper command should be:

codelite-make -w fplog.workspace -p spipc_test -c Release -d rebuild -e

However, even when you pass the correct workspace configuration name (i.e. Release), it still fails - this is because of a bug... which is now fixed.

In general, codelite-make should behave the same as the UI: In the UI you select the workspace configuration from the drop-down list (at the top of the workspace tab) and you hit F7. You don't need to pass the project configuration name (e.g. Release-32bit), since it is already mapped to the workspace configuration (e.g. Release)

I also updated the codelite-make usage text to clearly indicate that you need to pass the workspace configuration name and not the project configuration name.

I hope I am clear, if not, please consider reading this: http://codelite.org/LiteEditor/ConfigurationManager

@eranif eranif closed this in 37e91bf May 10, 2017

@kr0st

This comment has been minimized.

Show comment
Hide comment
@kr0st

kr0st May 10, 2017

Thanks for the fix! Everything is absolutely clear.

kr0st commented May 10, 2017

Thanks for the fix! Everything is absolutely clear.

@eranif

This comment has been minimized.

Show comment
Hide comment
@eranif

eranif May 10, 2017

Owner

I have uploaded CodeLite 10.0.4 to the website which should contains the fix. Please give it a try

Owner

eranif commented May 10, 2017

I have uploaded CodeLite 10.0.4 to the website which should contains the fix. Please give it a try

@kr0st

This comment has been minimized.

Show comment
Hide comment
@kr0st

kr0st May 11, 2017

Fix confirmed, now I get "[ERROR ] Could not find workspace configuration: Release-32bit" if I supply project configuration name instead of workspace configuration to codelite-make. In case I use existing workspace configuration name like "Release" codelite-make is able to build it when in the version 10.0.3 that failed with another error message.

kr0st commented May 11, 2017

Fix confirmed, now I get "[ERROR ] Could not find workspace configuration: Release-32bit" if I supply project configuration name instead of workspace configuration to codelite-make. In case I use existing workspace configuration name like "Release" codelite-make is able to build it when in the version 10.0.3 that failed with another error message.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment