How do I get hostname on running machine from skill?

S

Svenn Are Bjerkem

Guest
A simple question that it is hard to find an answer to. In the cdsFinder
there were no hits and pure luck made that I found getHostName(). There
is no documentation on this function so I wonder if it is a cadence
private one or one that has been invented by our integrators....

--
Svenn
 
Andrew,

BTW, is there any reason why you're doing funcall('sklint ...) rather than
just sklint(...) ? I changed the code to call sklint directly, and it works
fine (I couldn't see why it shouldn't).
I thought there was one, but indeed there is none.
I changed the code too, thanks,

Bernd
 
procedure( BFgetHostName( )
getHostName( )
)

SKILL lint result for the above procedure, so 'getHostName' must be public,
but I agree it is not documented so far, neither in the SKILL Finder nor in
cdsdoc.

I'm sure John Gianni or Andrew Beckett can comment this.


INFO (REP008): Program SKILL Lint started on Feb 10 12:04:18 2005.
INFO (PREFIXES): Using prefixes: "none"
INFO (STRICT): Using strict checking of global variables.
INFO (IQ): IQ score is 100 (best is 100).
INFO (IQ1): IQ score is based on 0 error messages, 0 general warning messages,
and 1 top level forms.
INFO (REP110): Total enhancement : 0.
INFO (REP110): Total external global : 0.
INFO (REP110): Total package global : 0.
INFO (REP110): Total warning global : 0.
INFO (REP110): Total error global : 0.
INFO (REP110): Total unused vars : 0.
INFO (REP110): Total next release : 0.
INFO (REP110): Total alert : 0.
INFO (REP110): Total hint : 0.
INFO (REP110): Total suggestion : 0.
INFO (REP110): Total internal alert : 0.
INFO (REP110): Total information : 24.
INFO (REP110): Total warning : 0.
INFO (REP110): Total error : 0.
INFO (REP110): Total internal error : 0.
INFO (REP110): Total fatal error : 0.
INFO (REP009): Program SKILL Lint finished on Feb 10 12:04:18 2005 with status PASS.


Bernd

Svenn Are Bjerkem wrote:
A simple question that it is hard to find an answer to. In the cdsFinder
there were no hits and pure luck made that I found getHostName(). There
is no documentation on this function so I wonder if it is a cadence
private one or one that has been invented by our integrators....
 
Bernd,

It is private. If you'd turned on the "Cadence Functions" checkbox on the
SKILL Lint form, you'd have seen that.

There was a PCR (223381) where our friend John Gianni asked for a public
equivalent. Unfortunately the public equivalent he was given, used another
private function!

However, I have reopened this PCR and asked for clarification. The replacement
function that was suggested probably could be public - let's just see what R&D
say.

Andrew.

On Thu, 10 Feb 2005 12:12:53 +0100, Bernd Fischer
<""bernd.fischer\"@xignal-A%&HY%$v#&G=.de"> wrote:

procedure( BFgetHostName( )
getHostName( )
)

SKILL lint result for the above procedure, so 'getHostName' must be public,
but I agree it is not documented so far, neither in the SKILL Finder nor in
cdsdoc.

I'm sure John Gianni or Andrew Beckett can comment this.


INFO (REP008): Program SKILL Lint started on Feb 10 12:04:18 2005.
INFO (PREFIXES): Using prefixes: "none"
INFO (STRICT): Using strict checking of global variables.
INFO (IQ): IQ score is 100 (best is 100).
INFO (IQ1): IQ score is based on 0 error messages, 0 general warning messages,
and 1 top level forms.
INFO (REP110): Total enhancement : 0.
INFO (REP110): Total external global : 0.
INFO (REP110): Total package global : 0.
INFO (REP110): Total warning global : 0.
INFO (REP110): Total error global : 0.
INFO (REP110): Total unused vars : 0.
INFO (REP110): Total next release : 0.
INFO (REP110): Total alert : 0.
INFO (REP110): Total hint : 0.
INFO (REP110): Total suggestion : 0.
INFO (REP110): Total internal alert : 0.
INFO (REP110): Total information : 24.
INFO (REP110): Total warning : 0.
INFO (REP110): Total error : 0.
INFO (REP110): Total internal error : 0.
INFO (REP110): Total fatal error : 0.
INFO (REP009): Program SKILL Lint finished on Feb 10 12:04:18 2005 with status PASS.


Bernd

Svenn Are Bjerkem wrote:
A simple question that it is hard to find an answer to. In the cdsFinder
there were no hits and pure luck made that I found getHostName(). There
is no documentation on this function so I wonder if it is a cadence
private one or one that has been invented by our integrators....
 
Andrew,

To be honest we don't have a SKILL dev. license,
therefore I use the following wrapper around 'sklint'.
I'm just wondering why the '?checkCdsFuncs'
(added it after your posting) is not true?

Bernd

procedure( XIsklint( @key ( file nil ) ( edit t ) )
let( (
l_stringList t_fileName t_tmpFile
)

l_stringList = parseString( file "/" )
t_fileName = nth( ( length( l_stringList ) - 1 ) l_stringList )
t_tmpFile = strcat( "/tmp/" t_fileName ".sklint" )
funcall(
'sklint
?file file
?noPrintLog t
?outputFile t_tmpFile
?checkCdsFuncs t
)

cond(
( edit == nil
view( t_tmpFile )
)
( t
edit( strcat( "/tmp/" t_fileName ".sklint" ) )
)
) ;; close cond


) ;; close let

) ;; close XIsklint


Andrew Beckett wrote:
Bernd,

It is private. If you'd turned on the "Cadence Functions" checkbox on the
SKILL Lint form, you'd have seen that.

There was a PCR (223381) where our friend John Gianni asked for a public
equivalent. Unfortunately the public equivalent he was given, used another
private function!

However, I have reopened this PCR and asked for clarification. The replacement
function that was suggested probably could be public - let's just see what R&D
say.

Andrew.

On Thu, 10 Feb 2005 12:12:53 +0100, Bernd Fischer
""bernd.fischer\"@xignal-A%&HY%$v#&G=.de"> wrote:


procedure( BFgetHostName( )
getHostName( )
)

SKILL lint result for the above procedure, so 'getHostName' must be public,
but I agree it is not documented so far, neither in the SKILL Finder nor in
cdsdoc.

I'm sure John Gianni or Andrew Beckett can comment this.


INFO (REP008): Program SKILL Lint started on Feb 10 12:04:18 2005.
INFO (PREFIXES): Using prefixes: "none"
INFO (STRICT): Using strict checking of global variables.
INFO (IQ): IQ score is 100 (best is 100).
INFO (IQ1): IQ score is based on 0 error messages, 0 general warning messages,
and 1 top level forms.
INFO (REP110): Total enhancement : 0.
INFO (REP110): Total external global : 0.
INFO (REP110): Total package global : 0.
INFO (REP110): Total warning global : 0.
INFO (REP110): Total error global : 0.
INFO (REP110): Total unused vars : 0.
INFO (REP110): Total next release : 0.
INFO (REP110): Total alert : 0.
INFO (REP110): Total hint : 0.
INFO (REP110): Total suggestion : 0.
INFO (REP110): Total internal alert : 0.
INFO (REP110): Total information : 24.
INFO (REP110): Total warning : 0.
INFO (REP110): Total error : 0.
INFO (REP110): Total internal error : 0.
INFO (REP110): Total fatal error : 0.
INFO (REP009): Program SKILL Lint finished on Feb 10 12:04:18 2005 with status PASS.


Bernd

Svenn Are Bjerkem wrote:

A simple question that it is hard to find an answer to. In the cdsFinder
there were no hits and pure luck made that I found getHostName(). There
is no documentation on this function so I wonder if it is a cadence
private one or one that has been invented by our integrators....
 
Bernd,

You mean why isn't it on by default? The main reason being that when it was
introduced, we didn't want to suddenly change people's SKILL Lint output
(including internal SKILL Lint runs).

That said, this is one of those things that personally I would probably have
made to be on by default. But I'm sure some customers would have complained...

You can't win, unfortunately, in these situations.

BTW, is there any reason why you're doing funcall('sklint ...) rather than
just sklint(...) ? I changed the code to call sklint directly, and it works
fine (I couldn't see why it shouldn't).

Regards,

Andrew.

On Thu, 10 Feb 2005 18:06:26 +0100, Bernd Fischer
<""bernd.fischer\"@xignal-A%&HY%$v#&G=.de"> wrote:

Andrew,

To be honest we don't have a SKILL dev. license,
therefore I use the following wrapper around 'sklint'.
I'm just wondering why the '?checkCdsFuncs'
(added it after your posting) is not true?

Bernd

procedure( XIsklint( @key ( file nil ) ( edit t ) )
let( (
l_stringList t_fileName t_tmpFile
)

l_stringList = parseString( file "/" )
t_fileName = nth( ( length( l_stringList ) - 1 ) l_stringList )
t_tmpFile = strcat( "/tmp/" t_fileName ".sklint" )
funcall(
'sklint
?file file
?noPrintLog t
?outputFile t_tmpFile
?checkCdsFuncs t
)

cond(
( edit == nil
view( t_tmpFile )
)
( t
edit( strcat( "/tmp/" t_fileName ".sklint" ) )
)
) ;; close cond


) ;; close let

) ;; close XIsklint


Andrew Beckett wrote:
Bernd,

It is private. If you'd turned on the "Cadence Functions" checkbox on the
SKILL Lint form, you'd have seen that.

There was a PCR (223381) where our friend John Gianni asked for a public
equivalent. Unfortunately the public equivalent he was given, used another
private function!

However, I have reopened this PCR and asked for clarification. The replacement
function that was suggested probably could be public - let's just see what R&D
say.

Andrew.

On Thu, 10 Feb 2005 12:12:53 +0100, Bernd Fischer
""bernd.fischer\"@xignal-A%&HY%$v#&G=.de"> wrote:


procedure( BFgetHostName( )
getHostName( )
)

SKILL lint result for the above procedure, so 'getHostName' must be public,
but I agree it is not documented so far, neither in the SKILL Finder nor in
cdsdoc.

I'm sure John Gianni or Andrew Beckett can comment this.


INFO (REP008): Program SKILL Lint started on Feb 10 12:04:18 2005.
INFO (PREFIXES): Using prefixes: "none"
INFO (STRICT): Using strict checking of global variables.
INFO (IQ): IQ score is 100 (best is 100).
INFO (IQ1): IQ score is based on 0 error messages, 0 general warning messages,
and 1 top level forms.
INFO (REP110): Total enhancement : 0.
INFO (REP110): Total external global : 0.
INFO (REP110): Total package global : 0.
INFO (REP110): Total warning global : 0.
INFO (REP110): Total error global : 0.
INFO (REP110): Total unused vars : 0.
INFO (REP110): Total next release : 0.
INFO (REP110): Total alert : 0.
INFO (REP110): Total hint : 0.
INFO (REP110): Total suggestion : 0.
INFO (REP110): Total internal alert : 0.
INFO (REP110): Total information : 24.
INFO (REP110): Total warning : 0.
INFO (REP110): Total error : 0.
INFO (REP110): Total internal error : 0.
INFO (REP110): Total fatal error : 0.
INFO (REP009): Program SKILL Lint finished on Feb 10 12:04:18 2005 with status PASS.


Bernd

Svenn Are Bjerkem wrote:

A simple question that it is hard to find an answer to. In the cdsFinder
there were no hits and pure luck made that I found getHostName(). There
is no documentation on this function so I wonder if it is a cadence
private one or one that has been invented by our integrators....
 
Svenn Are Bjerkem wrote:

A simple question that it is hard to find an answer to. In the cdsFinder
there were no hits and pure luck made that I found getHostName(). There
is no documentation on this function so I wonder if it is a cadence
private one or one that has been invented by our integrators....

use IPC and the hostname executable ?
Why ask from dfII to do what the OS has abstracted well enough ?

It would be sooo nice to get an interface to system libs and shared
objects, tho.
 

Welcome to EDABoard.com

Sponsor

Back
Top