61#ifdef FC_COMMAND_LINE_MODULE
62 use fc_command_line_module
67#ifdef FC_COMMAND_LINE_INCLUDE
68 include fc_command_line_include
86#if FC_COMMAND_LINE_ARGUMENTS != 2003
88 command_argument_count, &
105 character(len=*),
intent(in) :: config_str
122 character(len=*),
intent(inout) :: fname
127 integer,
intent(inout) :: mode
135 order, nresonances, nfrequencies, time, &
139 integer,
intent(inout) :: mode
140 real(c_double),
intent(inout) :: omega
141 real(c_double),
intent(inout) :: searchinterval
142 integer,
intent(inout) :: order, nresonances, nfrequencies
143 real(c_double),
intent(inout) :: time
144 integer,
intent(inout) :: l, m
145 real(c_double),
intent(inout) :: damping
146 character(len=*),
intent(inout) :: file
152 real(c_double) ,
intent(inout) :: w0
153 integer ,
intent(inout) :: m
154 integer ,
intent(inout) :: ar
155 character(len=*) ,
intent(inout) :: pol
156 real(c_double) ,
intent(inout) :: x
157 real(c_double) ,
intent(inout) :: y
158 real(c_double) ,
intent(inout) :: z
163 character(len=*),
intent(inout) :: mode
164 character(len=*),
intent(inout) :: name
168 thstep, thspan, phstep, phspan, pol, center, pvec, integrate)
171 real(c_double),
intent(inout) :: estep
172 real(c_double),
intent(inout) :: espan(2)
173 real(c_double),
intent(inout) :: thstep
174 real(c_double),
intent(inout) :: thspan(2)
175 real(c_double),
intent(inout) :: phstep
176 real(c_double),
intent(inout) :: phspan(2)
177 real(c_double),
intent(inout) :: pol(3)
178 real(c_double),
intent(inout) :: center(3)
179 real(c_double),
intent(inout) :: pvec(3)
180 integer,
intent(inout) :: integrate
190#if FC_COMMAND_LINE_ARGUMENTS == 77 && ! defined(FC_COMMAND_LINE_INTRINSIC)
192 interface command_argument_count
193#ifdef FC_COMMAND_LINE_IMPLICIT
194 integer function iargc()
198 module procedure iargc
202 interface get_command_argument
203#ifdef FC_COMMAND_LINE_IMPLICIT
204 subroutine getarg(c, a)
206 integer,
intent(in) :: c
207 character(len=*),
intent(out) :: a
208 end subroutine getarg
210 module procedure getarg
214#endif /* FC_COMMAND_LINE_ARGUMENTS == 77 */
224 integer,
intent(in) :: argc
229 integer,
intent(in) :: i
230 character(len=*),
intent(in) :: argstring
247 integer,
intent(out) :: ierr
250 character(len=100),
allocatable :: argstring(:)
252#ifdef FC_COMMAND_LINE_ARGUMENTS
253 argc = command_argument_count()
254 allocate(argstring(0:argc))
257 call get_command_argument(i, argstring(i))
260 deallocate(argstring)
269#ifdef FC_COMMAND_LINE_ARGUMENTS
277#if defined(FC_COMMAND_LINE_INTRINSIC) || ! defined(FC_COMMAND_LINE_ARGUMENTS)
279 integer function command_argument_count()
280#if defined(FC_COMMAND_LINE_INTRINSIC)
281 command_argument_count = iargc()
283 command_argument_count = 0
285 end function command_argument_count
287 subroutine get_command_argument(c, a)
288 integer,
intent(in) :: c
289 character(len=*),
intent(out) :: a
291#if defined(FC_COMMAND_LINE_INTRINSIC)
295 end subroutine get_command_argument
Each program/utility that needs to use the getopt features should have an interface here – the defini...
If Fortran 2003 interface to command line arguments is not available, define it using an interface ov...
subroutine, public getopt_init(ierr)
Initializes the getopt machinery. Must be called before attempting to parse the options....
subroutine, public getopt_end