[ROOT] LinkDef file commend line flag for rootcint (and makecint?)

From: Christian Holm Christensen (cholm@hehi03.nbi.dk)
Date: Thu May 11 2000 - 22:31:21 MEST


Hi ROOT'ers, 

Recently I've gotten quite frustrated by the strict command line
syntax of rootcint. The requirement that the LinkDef.h file _must_ be
the last file name on the commandline seems way too strict. Also, that
the names _must_ end in LinkDef.h also, IMHO, too restrictive. 

Therefore, I'd like to propose using commandline switches for
specification of the LinkDef file. The commandline syntax could
"GNU'ish" that 

        -f --force        : Force recreation of dictonary code
	-c --create-stubs : Create stubs
	-l --link-file    : LinkDef file flag
	-S --source-out   : Implmentation output file
	-H --header-out   : Decleration output file
	-h --help	  : Show help
	-V --version	  : Show version information
	-I                : *SPECIAL* include paths
	-D		  : *SPECIAL* preprocessor define
	-U		  : *SPECIAL* preprocessor un-define

so that a commen line previously written

  rootcint -f FooCint.cxx -c -I/my/foo/dir Foo.h FooLinkDef.h 

could be written as any of 

  rootcint -f -c -S FooCint.cxx -H FooCint.h -l FooLinkDef.h \
	   -I/my/foo/dir  Foo.h

  rootcint -I/my/foo/dir -fcS FooCint.cxx -H FooCint.h \
	   -l FooLinkDef.h Foo.h 

  rootcint --force -c --source-out=FooCint.cxx -I/my/foo/dir \
	   --header-out=FooCint.h \
	   --link-file=FooLinkDef.h Foo.h 

however, the file names (the LinkDef file in particular) need not be
similar as above, but could be anything. Suppose I wanted Dictonary
implementation in Bar.cc, declaration in Baz.hh, LinkDef stuff in
Gnus.hh and my class Declarations in Gnat.hh, then I could do 

  rootcint -fc -S Bar.cc -H Baz.hh -l Gnus.hh Gnat.hh

Also notice how you can concencate the short options. 

I could imagine that a similar scheme would be usefull for the "root"
application. 

I've created a set of classes that helps one make such a commandline
syntax. I've attached these classes. 

I hope that you'll find these suggestions useful. 

Cheers, 

Christian  -----------------------------------------------------------
Holm Christensen                             Phone:  (+45) 35 35 96 91 
  Sankt Hansgade 23, 1. th.                  Office: (+45) 353  25 305 
  DK-2200 Copenhagen N                       Web:    www.nbi.dk/~cholm    
  Denmark                                    Email:       cholm@nbi.dk












This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:25 MET