Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » CDT and SCons
CDT and SCons [message #75630] Mon, 14 July 2003 22:03 Go to next message
Eclipse UserFriend
Originally posted by: lothar.xcerla.com

Has anyone tried to integrate SCons (http://www.scons.org/) into
eclipse? Eclipse already knows all the files in the directories and
could generate automatically files imported by SConstruct. What's needed
is something like one line per file which looks like:

env.SharedObject(target = 'eee.o', source = 'eee.cpp')
or
env.StaticObject(target = 'bbb.o', source = 'bbb.cpp')

depending if shared or static libraries are to be buildt.



Lothar
Re: CDT and SCons [message #75717 is a reply to message #75630] Tue, 15 July 2003 20:48 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alain.nowhere.ca

Lothar Werzinger wrote:

> Has anyone tried to integrate SCons (http://www.scons.org/) into

The link does not seem to work.

> eclipse? Eclipse already knows all the files in the directories and
> could generate automatically files imported by SConstruct. What's needed
> is something like one line per file which looks like:

> env.SharedObject(target = 'eee.o', source = 'eee.cpp')
> or
> env.StaticObject(target = 'bbb.o', source = 'bbb.cpp')

> depending if shared or static libraries are to be buildt.


You would need to create a new Eclipse builder and set it to the project
I suppose that would be one way of implementing.

> Lothar
Re: CDT and SCons [message #75942 is a reply to message #75717] Wed, 16 July 2003 14:56 Go to previous messageGo to next message
John Camelon is currently offline John CamelonFriend
Messages: 50
Registered: July 2009
Member
"alain" <alain@nowhere.ca> wrote in message news:bf1paq$j1q$1@eclipse.org...
> Lothar Werzinger wrote:
>
> > Has anyone tried to integrate SCons (http://www.scons.org/) into
>
> The link does not seem to work.

The link goes up and down. Its up now.

> > eclipse? Eclipse already knows all the files in the directories and
> > could generate automatically files imported by SConstruct. What's needed
> > is something like one line per file which looks like:
>
> > env.SharedObject(target = 'eee.o', source = 'eee.cpp')
> > or
> > env.StaticObject(target = 'bbb.o', source = 'bbb.cpp')
>
> > depending if shared or static libraries are to be buildt.
>
>
> You would need to create a new Eclipse builder and set it to the project
> I suppose that would be one way of implementing.
>
> > Lothar
>
>
Re: CDT and SCons [message #83093 is a reply to message #75630] Wed, 15 October 2003 05:00 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: john.mlist.arrizza.com

"Lothar Werzinger" <lothar@xcerla.com> wrote in message
news:bev9dm$12d$1@eclipse.org...
> Has anyone tried to integrate SCons (http://www.scons.org/) into
> eclipse? Eclipse already knows all the files in the directories and
> could generate automatically files imported by SConstruct. What's needed
> is something like one line per file which looks like:
>
> env.SharedObject(target = 'eee.o', source = 'eee.cpp')
> or
> env.StaticObject(target = 'bbb.o', source = 'bbb.cpp')
>
> depending if shared or static libraries are to be buildt.

If you're willing to tolerate a more manual-intensive solution:
Here's the SConstruct, assuming an executable is being built:

import glob
env = Environment(tools=['mingw'])
env.Program(target='mytarget', source = Split(glob.glob('*.cpp')))

The build command is:
scons .

This is on a Win32 platform using mingw. To compile using MSVC, even easier:
import glob
env = Environment()
env.Program(target='mytarget', source = Split(glob.glob('*.cpp')))

Not as nice as you're proposing but very simple. I do like makefiles, but
IMO this script is much easier to maintain.



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.525 / Virus Database: 322 - Release Date: 10/9/2003
Re: CDT and SCons [message #124569 is a reply to message #75630] Thu, 21 October 2004 08:28 Go to previous messageGo to next message
Remy Rakic is currently offline Remy RakicFriend
Messages: 6
Registered: July 2009
Junior Member
Actually, i believe the view 'make targets' allows you to choose which
command to execute, so you could create a target that launches scons. Or
anything else for that matter.

hope that helps


Lothar Werzinger wrote:

> Has anyone tried to integrate SCons (http://www.scons.org/) into
> eclipse? Eclipse already knows all the files in the directories and
> could generate automatically files imported by SConstruct. What's needed
> is something like one line per file which looks like:
>
> env.SharedObject(target = 'eee.o', source = 'eee.cpp')
> or
> env.StaticObject(target = 'bbb.o', source = 'bbb.cpp')
>
> depending if shared or static libraries are to be buildt.
>
>
>
> Lothar
>
Re: CDT and SCons [message #124602 is a reply to message #75630] Thu, 21 October 2004 16:45 Go to previous messageGo to next message
Uwe Fechner is currently offline Uwe FechnerFriend
Messages: 16
Registered: July 2009
Junior Member
Lothar Werzinger schrieb:
> Has anyone tried to integrate SCons (http://www.scons.org/) into
> eclipse? Eclipse already knows all the files in the directories and
> could generate automatically files imported by SConstruct. What's needed
> is something like one line per file which looks like:

Yes,

in our company we rely heavily on scons and cdt.

I created a simple make file, that calls scons (because of easy make
target integration of exclipse).

What we do in our build process:

- eclipse calls
- make calls
- scons
- calls keil c compiler (I builded python wrappers for it, to make the
output parseble by eclipse)
- and calls other build tools, like an xml to c converter, written in
delphi
- and scons also calls a delphi tool, that itself calls and parses
the output of our svn version control tool

If someone is interested, I could publish an example setup in the
future.

Regards:

Uwe Fechner
Re: CDT and SCons [message #124647 is a reply to message #124569] Thu, 21 October 2004 23:43 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: lothar.xcerla.com

Remy Rakic wrote:

> Actually, i believe the view 'make targets' allows you to choose which
> command to execute, so you could create a target that launches scons. Or
> anything else for that matter.
>
> hope that helps
>
>
> Lothar Werzinger wrote:
>
>> Has anyone tried to integrate SCons (http://www.scons.org/) into
>> eclipse?

I solved the problem myself by creating a SCons Builder plugin.

This plugin allows to build C/C++ projects with the SCons build tool. In
order to use it you must install SCons first. I tested it with release
0.95, but it should work also with newer versions. The source of the plugin
is included.

Maybe you can look at the plugin and mention it in your magazine.

The plugin can be installed/updated easily through Eclipse built-in
Install/Update Mechanism. Just add
http://nic-nac-project.de/~lothar/eclipse/update/ to your list of Update
Sites. Please see the Eclipse help for information on installing feature
plugins through Eclipse's Update Mechanism.

For more information see
http://nic-nac-project.de/~lothar/eclipse/update/SConsBuilde rPlugin.html

Please let me know your opinions about the plugin.

The plugin is also registed at http://eclipse-plugins.2y.net and users can
rate it at http://eclipse-plugins.2y.net/eclipse/plugin_details.

Lothar
Re: CDT and SCons [message #124657 is a reply to message #124602] Thu, 21 October 2004 23:44 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: lothar.xcerla.com

ufechner@sk28.de wrote:

> Lothar Werzinger schrieb:
>> Has anyone tried to integrate SCons (http://www.scons.org/) into
>> eclipse?

I solved the problem myself by creating a SCons Builder plugin.

This plugin allows to build C/C++ projects with the SCons build tool. In
order to use it you must install SCons first. I tested it with release
0.95, but it should work also with newer versions. The source of the plugin
is included.

Maybe you can look at the plugin and mention it in your magazine.

The plugin can be installed/updated easily through Eclipse built-in
Install/Update Mechanism. Just add
http://nic-nac-project.de/~lothar/eclipse/update/ to your list of Update
Sites. Please see the Eclipse help for information on installing feature
plugins through Eclipse's Update Mechanism.

For more information see
http://nic-nac-project.de/~lothar/eclipse/update/SConsBuilde rPlugin.html

Please let me know your opinions about the plugin.

The plugin is also registed at http://eclipse-plugins.2y.net and users can
rate it at http://eclipse-plugins.2y.net/eclipse/plugin_details.

Lothar
Re: CDT and SCons [message #1817723 is a reply to message #124657] Thu, 28 November 2019 09:22 Go to previous message
Hariharan Murugesan is currently offline Hariharan MurugesanFriend
Messages: 1
Registered: November 2019
Junior Member
Hello Everyone,

I am starting to Pilot SCONS and SCONS with CDT IDE for one of our Project.
Standalone SCONS works fine for me. As a next step, I would like to integrate SCONS with eclipse CDT IDE. When I tried to call SCONS build, I am getting Errors such as "Error configuring SCons project.".

I searched in Internet however I could to get detailed explanation about how to configure SCONS with CDT IDE.

Can anyone share throw some light on it.

Thanks.

Cheers,
Hariharan
Previous Topic:Can't get C/C++ IDE working
Next Topic:unmanaged make files project howto
Goto Forum:
  


Current Time: Thu Jan 02 13:17:30 GMT 2025

Powered by FUDForum. Page generated in 0.03748 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top