This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Re: Access version number string of eCos to check the compile date


>>>>> "Carlos" == Carlos Sobrinho <duckman@epilog.ath.cx> writes:

    >> A timestamp seems the best way to differentiate between builds.
    Carlos> So can I implement cyg(_kernel)_ver(sion) ?
    Carlos> With a simple __DATA__ to show the compile date?

    Carlos> And if its a release also show the eCos branch (2.0 ,
    Carlos> 2.0b) or if its cvs show CVS something like:

    Carlos>  "eCos compiled on __DATA__ [ 2.0 branch ]"
    Carlos>  "eCos compiled on __DATA__ [ CVS branch ]"

I think that should be __DATE__ and __TIME__. 

    Carlos> Would this be feasible for inclusion?

The version of the kernel is already readily available using something
like:

  #include <pkgconf/system.h>
  #include <stdio.h>

  #define PACKAGE_VERSION(_a_) # _a_

  int
  main(int argc, char** argv)
  {
      printf("Kernel version %s\n", PACKAGE_VERSION(CYGPKG_KERNEL));
  }

I don't think having a separate variable for this would gain you
anything.

Versioning applies on a per-package basis. For the V2 release every
package was assigned a version 2.0, but this was arbitrary. It would
have been just as valid for the 2.0 tarball to contain a kernel 1.204,
a TCP/IP stack 2.37, a C stdlib library 1.10, and so on - depending on
how frequently each package changes. Conceptually each package can be
upgraded independently from other packages, thus diverging from the
release. Third party packages are likely to have their own version
numbers.

Hence there is no information anywhere that the system as a whole is
based on a 2.0 release. The only version information is for each
individual package.

Bart

-- 
Bart Veer                       eCos Configuration Architect
http://www.ecoscentric.com/     The eCos and RedBoot experts

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]