comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Is System Dependent Compilation Possible?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Is System Dependent Compilation Possible? [message #6108 is a reply to message #6104] Thu, 25 April 1996 00:00 Go to previous message
plugge is currently offline  plugge
Messages: 17
Registered: May 1995
Junior Member
In article <317EE71F.31D2@raptor.lpl.arizona.edu>, Tim Patterson <tim@raptor.lpl.arizona.edu> writes:
|>I have a tool written in IDL/Fortran and C that needs to
|>run on both Unix and VMS systems. I have a few system
|>dependent IDL procedures that I use as wrappers for the
|>CALL_EXTERNALS.
|>
|>What I would like to do is have a batch file, say
|>compile.pro, which can be invoked with @compile.pro
|>and will compile the correct version of wrappers
|>depending upon the OS, e.g.
|>
|>
|>IF !version.os EQ 'vms' then begin
|>
|> .run vms_version.pro
|>
|>ENDIF ELSE BEGIN
|>
|> .run unix_version.pro
|>
|>ENDELSE
|>
|>
|>Unfortunately, I can't seem to come up with anything
|>that even approaches this.
|>
|> IF !version.os EQ 'vms' then .run vms_version.pro
|>
|>produces an error.
|>
|>
|>Anybody got any ideas?
|>
|> Thanks
|>
|> Tim
|>

Tim,
the problem is that the executive commands (for example, .run etc) cannot
be called from normal program code. You should make the distinction in the
procedure body, for example:

pro wrapper
IF !version.os EQ 'vms' then begin
print,"wrapper: VMS version"
(VMS code goes here)
endif else begin
print,"wraper: UNIX version"
(UNIX code goes here)
endif
end

best regards

Michel

------------------------------------------------------------ -------------
Michael Plugge _ Fachhochschule Mannheim
Institute for Statistics / \ Hochschule fuer Technik und Gestaltung
and Image Processing / \ Email: plugge@biv7.sr.fh-mannheim.de
Speyerer Str. 4 / \ Tel: 0621 2926208
68163 Mannheim / \ --o /\
Germany / -- - \<,- / \/\
/ \ (_)/ (_) / \/\
------------------------------------------------------------ -------------
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Are you using IDL in medicine/medical research?
Next Topic: Re: PS OUTPUT ON HP LASER JET

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 16:49:42 PDT 2025

Total time taken to generate the page: 0.00445 seconds