It is currently Thu Feb 09, 2012 12:53 am

All times are UTC



Welcome
Welcome to RHAPSODY4YOU

You are currently viewing our boards as a guest, which gives you limited access to view most discussions and access our other features. By joining our free community, you will have access to post topics, respond to polls, upload and download content, and access many other special features. Registration is fast, simple, and absolutely free, so please, register to join our community today.





 Page 1 of 1 [ 2 posts ] 
Author Message
 Post subject: Generated makefile to include external files
PostPosted: Wed Oct 14, 2009 3:35 pm 

Joined: Tue Feb 03, 2009 3:58 pm
Posts: 27
Location: Bonnie Scotland
I have a set of external .cpp and .c files (created outside of Rhapsody) that need to be included in builds, i.e. they need to appear in the makefile. The simplistic way of doing this is to list the files in the "Additional sources" line of a component, but this is a nuisance because a) there are quite a few of these files, so most of them are not visible in the "Additional sources" line, and b) there are a number of components that will use these external files. The combination of these means that when the set of files changes (not under my control!) there is a rigmarole of updating that needs to be done and the process is error-prone.

The Simulink integration somehow pulls in a load of external files into the makefile when they are listed in a tag under the Simulink block, so they are automatically included in any component that uses the Simulink block. But I'm not using the Simulink integration because it has problems.

I've submitted an enhancement request to IBM for an expansion of the code generation from dependencies between components: this is currently limited to the binary level (i.e. an executable build using a library), but if it could be expanded to build external source files in a depended-on component that would probably solve the problem. But as an enhancement I won't see that for a while yet and the problem is now.

Can anyone think of a neat way of avoiding the Additional Sources way of listing the source files?


Offline
 Profile  
 
 Post subject: Re: Generated makefile to include external files
PostPosted: Mon Oct 18, 2010 5:49 pm 

Joined: Wed Oct 31, 2007 3:09 pm
Posts: 58
Location: Milkyway, classic 9-planet solar system
One year later... :shock:

Did you fix your problem in the meanwhile, or has the requested enhancement been productized? :wink:

If not... would it be possible to put the list of your external files into a kind of "extFiles.list", which could then be included into the makefile generation template within the environment specific properties (property MakeFileContent)?
I think about an approach like in {RhpInstDir}\Share\LangCpp\oxf\ where all adapter specific makefiles like linuxoxf.mak and msoxf.mak include the (generated) generic list of oxf files, named "oxfFiles.list" in order to add them to any platform specific build process.
You could create a kind of "EnvWithExt" named environment, which adds such a file to the MakeFileContent and so uses it during the build process.

-Luke.



_________________
May the force be with you ...
Offline
 Profile  
 
Display posts from previous:  Sort by  
 Page 1 of 1 [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:


suspicion-preferred