Recipes4Linux 

Commercial Distribution - Monta Vista Linux

Murphy

Recipe 1a : tar fails to extract files from fsimage.tar?


tar fails to extract files from fsimage.tar?

The tar file that is generated by the targetconf tool is a binary file.  Most version control systems need to be explicitly told a file is binary when it is added to the repository.  This is true for CVS, which is the preferred open-source solution at this time.

The CVS command line is:

cvs add -kb fsimage.tar

Philosophical Debate

fsimage.tar is a derived file, since it is built by the GUI tool.  As a derived file you have to ask yourself why you want to put it under version control.  In this case, I think there are two very good reasons to do so.

  1. Since the tool that generates this file is a GUI, it is hard to automate build processes without having access to the derived file.
  2. Most projects will assign a single engineer the responsibility of keeping the target filesystem current as the project evolves.  All the engineers on the project team need access to the derived file, but only the assigned engineer needs to know how to use the GUI to build the derived file.

In this case, putting both the derived file (fsimage.tar) and the configuration file (XXX.cfg) under version control is a good idea.  Since the configuration file is also generated by the GUI tool and is, in fact, an XML file, you probably want to treat this as a binary file as well.


Contact  mailto:tmike@recipes4linux.com

Copyright © 2004 Tools Made Tough