Jump to content

Check out our Community Blogs

Register and join over 40,000 other developers!

Recent Status Updates

View All Updates

- - - - -

adding features in a source based distribution

source based distribution

This topic has been archived. This means that you cannot reply to this topic.
3 replies to this topic

#1 KansaiRobot


    CC Resident

  • Advanced Member
  • PipPipPipPip
  • 82 posts

Posted 04 December 2013 - 05:29 PM

Hello everybody. I would really appreciate if someone can help me with this problem.


First, I am using a source based distribution for development whatever that means  :confused:  I know that without knowing the details of this distribution it is hard to give a solution but any guess you could give is better than the total blindness I am in now.


So, I am reading the manual (the makers are a company that provides no support, they actually reject your calls) and I understood that to add features you have to modify the kernel and/or the user land through make config and then later re make all the system to build a image file that you can write to the flash memory. 


So for example if I want to use NFS I have to make config over the source code and activate that option and remake

If I want to use openCV I have to do the same


If I want to build an application and make it part of the user land, I have to add a "product folder" to the source, make config to select that product (my application) and re make.


So far so good, but what happen if say I want to add feature A today and feature B one week later?

Or even worse, what happen if a third party adds for me feature A (obviously they are not gonna give me their source code, at most maybe their object files) and then I want to add feature B?


All make config files are done over source code, at least so far I see, so what to do in this situation??


Thanks lots for any advice or idea you could give me




P.S. I know the advice you could give me is limited but it is still very much appreciated

#2 BlackRabbit


    CodeCall Legend

  • Expert Member
  • PipPipPipPipPipPipPipPip
  • 3871 posts

Posted 05 December 2013 - 05:49 AM

You should be able to work just with the object files, but it will take some time to make your bulletproof makefile.


About making after adding features, if you modularize, you could build incrementally, you just need the program to rely on many modular object files, libs, etc.

#3 WingedPanther73


    A spammer's worst nightmare

  • Moderator
  • 17757 posts

Posted 05 December 2013 - 06:38 AM

It sounds like you will basically have to understand the entire source code, or at least the relevant parts, to make changes. I would start by checking it into a revision control system, as you will want to be able to roll back changes, etc, as needed.


Every time you make a change, you will need to rebuild your project (run the make file). Depending on the scope of the changes you make, that may involve changing the make file as well.

Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

My MineCraft server site: http://banishedwings.enjin.com/

#4 gonerogue


    CC Addict

  • Advanced Member
  • PipPipPipPipPip
  • 197 posts

Posted 05 December 2013 - 07:02 AM

If the implementation of your new feature can be decoupled from the rest of the sources (is like a new component or plugin), it would be easier to build it using a different makefile.

So, when you will build your new application each component will be built from a separate makefile.

All those makefiles will be used by a master makefile, used to build the entire application.

This way it will be easier to maintain a logic in your build and to include/exclude a certain component from your build.

It will also allow you to perform minimal modifications to your master makefile when adding a new component (the build logic of the component will go in a separate makefile, which will only be used by the master makefile).

If the new feature will be implemented in an existing component, you will have to modify the makefile of that component.


In rest, you need to have what is commonly needed for a software project:

1. Version control system (git will be probably fine).

2. Tests (use a testing framework).

3. Automatic build system, used to produce builds, run tests and generate reports automatically (e.g during the night).


Good luck.

Edited by xyv123, 05 December 2013 - 07:03 AM.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download