1
/* $Id: plstubs.h,v 1.4 2006/05/18 01:13:29 airwin Exp $
4
IFS, University of Texas
6
Header file for plplot Fortran interface stubs.
7
THIS FILE IS NOT FOR INCLUSION BY USER CODES!!
9
The contents of this file are in the public domain.
17
/*----------------------------------------------------------------------*\
18
* Select name transformation based on system type.
20
* Define the STUB_LINKAGE flag to get proper C<->Fortran linkage on your
21
* system. This flag describes what the compiler does to Fortran routine
22
* names, which we must duplicate on the C stubs so that the Fortran
23
* routines may call them. You can often set STUB_LINKAGE by the
24
* construct -DSTUB_LINKAGE=<value> on the C compiler command line, but
25
* it is best to either rely on the default or explicitly handle your
28
* Current choices for STUB_LINKAGE:
30
* STUB_LAU lower-case, append underscore
33
* STUB_FORTRAN use "fortran" keyword (MS-DOS convention)
35
* If no choice is made, the default is set to STUB_LAU. This should
36
* handle most generic Unix boxes not already accounted for.
38
* ** Namespace collision **
40
* If you use the STUB_L option, the C & Fortran namespaces will collide
41
* if the Fortran compiler does lower case folding (they usually do).
42
* The problem is then that the stub names and actual function names will
43
* be exactly the same, if we insist on the Fortran and C bindings to be
44
* similar. The solution is to give the externally callable C routines
45
* unique names, and provide macros to turn the documented entry names in
46
* to the real ones. This is a horrible kludge, but the alternatives are
47
* worse. Fortunately it has no effect on the user program, and you can
48
* forget that you ever read about it here.
49
\*----------------------------------------------------------------------*/
54
#define STUB_FORTRAN 4
58
#if defined(SX) /* NEC Super-UX (SX-3) */
59
#define STUB_LINKAGE STUB_LAU
62
#if defined(_IBMR2) && defined(_AIX) /* AIX */
63
#define STUB_LINKAGE STUB_L
66
#ifdef __hpux /* HP/UX */
67
#define STUB_LINKAGE STUB_L
70
#ifdef __mips /* IRIX (SGI systems) */
71
#define STUB_LINKAGE STUB_LAU
75
#define STUB_LINKAGE STUB_LAU
78
#ifdef CRAY /* Cray/UNICOS */
79
#define STUB_LINKAGE STUB_U
82
#if defined(__alpha) && defined(__osf__) /* DEC Alpha AXP/OSF */
83
#define STUB_LINKAGE STUB_LAU
86
#ifdef __GO32__ /* dos386/djgpp */
92
#ifdef MSDOS /* MS-DOS based */
93
#define STUB_LINKAGE STUB_FORTRAN
96
#ifndef STUB_LINKAGE /* The default */
97
#define STUB_LINKAGE STUB_LAU
100
#endif /* ifndef STUB_LINKAGE */
102
/*----------------------------------------------------------------------*\
103
* Define name-translation macro.
104
* To use, define with x the upper case routine name, y the lower case.
105
* Should be adaptable to virtually any system.
106
\*----------------------------------------------------------------------*/
108
#if STUB_LINKAGE==STUB_LAU
109
#define FNAME(x,y) y##_
111
#elif STUB_LINKAGE == STUB_L
114
#elif STUB_LINKAGE == STUB_U
117
#elif STUB_LINKAGE == STUB_FORTRAN
118
#define FNAME(x,y) fortran x
121
#error "Illegal setting for STUB_LINKAGE"
124
/*----------------------------------------------------------------------*\
125
* Now to actually define the stub names.
126
* Each stub must have an entry here.
127
\*----------------------------------------------------------------------*/
129
/* N.B. By default the g77 compiler appends second underscore to name if
130
* the original name contains any underscore at all. According to info
131
* g77, "This is done to ensure compatibility with code produced by many
132
* UNIX Fortran compilers." However, other fortran compilers do not have
133
* this default naming scheme so to avoid trouble I have #defined two
134
* variations of the embedded underscore names, one with and one without
135
* the extra trailing underscore.
138
#define PL_SETCONTLABELFORMAT FNAME(PL_SETCONTLABELFORMAT,pl_setcontlabelformat)
139
#define PL_SETCONTLABELFORMATa FNAME(PL_SETCONTLABELFORMAT_,pl_setcontlabelformat_)
140
#define PL_SETCONTLABELPARAM FNAME(PL_SETCONTLABELPARAM,pl_setcontlabelparam)
141
#define PL_SETCONTLABELPARAMa FNAME(PL_SETCONTLABELPARAM_,pl_setcontlabelparam_)
142
#define PLADV FNAME(PLADV,pladv)
143
#define PLAXES7 FNAME(PLAXES7,plaxes7)
144
#define PLBIN FNAME(PLBINF77,plbinf77)
145
#define PLBOP FNAME(PLBOP,plbop)
146
#define PLBOX37 FNAME(PLBOX37,plbox37)
147
#define PLBOX7 FNAME(PLBOX7,plbox7)
148
#define PLCALC_WORLD FNAME(PLCALC_WORLD,plcalc_world)
149
#define PLCALC_WORLDa FNAME(PLCALC_WORLD_,plcalc_world_)
150
#define PLCLEAR FNAME(PLCLEAR,plclear)
151
#define PLCLR FNAME(PLCLR,plclr)
152
#define PLCOL FNAME(PLCOL,plcol)
153
#define PLCOL0 FNAME(PLCOL0,plcol0)
154
#define PLCOL1 FNAME(PLCOL1,plcol1)
155
#define PLCON07 FNAME(PLCON07,plcon07)
156
#define PLCON17 FNAME(PLCON17,plcon17)
157
#define PLCON27 FNAME(PLCON27,plcon27)
158
#define PLCONT7 FNAME(PLCONT7,plcont7)
159
#define PLCPSTRM FNAME(PLCPSTRMF77,plcpstrmf77)
160
#define PLEND FNAME(PLEND,plend)
161
#define PLEND1 FNAME(PLEND1,plend1)
162
#define PLENV FNAME(PLENV,plenv)
163
#define PLEOP FNAME(PLEOP,pleop)
164
#define PLERRX FNAME(PLERRXF77,plerrxf77)
165
#define PLERRY FNAME(PLERRYF77,plerryf77)
166
#define PLFAMADV FNAME(PLFAMADV,plfamadv)
167
#define PLFILL FNAME(PLFILLF77,plfillf77)
168
#define PLFILL3 FNAME(PLFILL3F77,plfill3f77)
169
#define PLFLUSH FNAME(PLFLUSH,plflush)
170
#define PLFONT FNAME(PLFONT,plfont)
171
#define PLFONTLD FNAME(PLFONTLD,plfontld)
172
#define PLGCHR FNAME(PLGCHR,plgchr)
173
#define PLGCOL0 FNAME(PLGCOL0,plgcol0)
174
#define PLGCOLBG FNAME(PLGCOLBG,plgcolbg)
175
#define PLGCOMPRESSION FNAME(PLGCOMPRESSION,plgcompression)
176
#define PLGDEV7 FNAME(PLGDEV7,plgdev7)
177
#define PLGDIDEV FNAME(PLGDIDEV,plgdidev)
178
#define PLGDIORI FNAME(PLGDIORI,plgdiori)
179
#define PLGDIPLT FNAME(PLGDIPLT,plgdiplt)
180
#define PLGFAM FNAME(PLGFAM,plgfam)
181
#define PLGFNAM7 FNAME(PLGFNAM7,plgfnam7)
182
#define PLGLEVEL FNAME(PLGLEVEL,plglevel)
183
#define PLGPAGE FNAME(PLGPAGE,plgpage)
184
#define PLGRA FNAME(PLGRA,plgra)
185
#define PLGRIDDATA FNAME(PLGRIDDATAF77,plgriddataf77)
186
#define PLGSPA FNAME(PLGSPA,plgspa)
187
#define PLGSTRM FNAME(PLGSTRM,plgstrm)
188
#define PLGVER7 FNAME(PLGVER7,plgver7)
189
#define PLGVPD FNAME(PLGVPD,plgvpd)
190
#define PLGVPW FNAME(PLGVPW,plgvpw)
191
#define PLGXAX FNAME(PLGXAX,plgxax)
192
#define PLGYAX FNAME(PLGYAX,plgyax)
193
#define PLGZAX FNAME(PLGZAX,plgzax)
194
#define PLHIST FNAME(PLHISTF77,plhistf77)
195
#define PLHLS FNAME(PLHLS,plhls)
196
#define PLHLSRGB FNAME(PLHLSRGB,plhlsrgb)
197
#define PLINIT FNAME(PLINIT,plinit)
198
#define PLJOIN FNAME(PLJOIN,pljoin)
199
#define PLLAB7 FNAME(PLLAB7,pllab7)
200
#define PLLIGHTSOURCE FNAME(PLLIGHTSOURCE,pllightsource)
201
#define PLLINE FNAME(PLLINEF77,pllinef77)
202
#define PLLINE3 FNAME(PLLINE3F77,plline3f77)
203
#define PLLSTY FNAME(PLLSTY,pllsty)
204
#define PLMAPC FNAME(PLMAPC,plmapc)
205
#define PLMERIDIANSC FNAME(PLMERIDIANSC,plmeridiansc)
206
#define PLMESH FNAME(PLMESHF77,plmeshf77)
207
#define PLMESHC FNAME(PLMESHCF77,plmeshcf77)
208
#define PLMKSTRM FNAME(PLMKSTRM,plmkstrm)
209
#define PLMTEX7 FNAME(PLMTEX7,plmtex7)
210
#define PLOT3D FNAME(PLOT3DF77,plot3df77)
211
#define PLOT3DC FNAME(PLOT3DCF77,plot3dcf77)
212
#define PLPARSEOPTS7 FNAME(PLPARSEOPTS7,plparseopts7)
213
#define PLPAT FNAME(PLPAT,plpat)
214
#define PLPOIN FNAME(PLPOINF77,plpoinf77)
215
#define PLPOIN3 FNAME(PLPOIN3F77,plpoin3f77)
216
#define PLPOLY3 FNAME(PLPOLY3F77,plpoly3f77)
217
#define PLPREC FNAME(PLPREC,plprec)
218
#define PLPSTY FNAME(PLPSTY,plpsty)
219
#define PLPTEX7 FNAME(PLPTEX7,plptex7)
220
#define PLREPLOT FNAME(PLREPLOT,plreplot)
221
#define PLRGB FNAME(PLRGB,plrgb)
222
#define PLRGB1 FNAME(PLRGB1,plrgb1)
223
#define PLRGBHLS FNAME(PLRGBHLS,plrgbhls)
224
#define PLSCHR FNAME(PLSCHR,plschr)
225
#define PLSCMAP0 FNAME(PLSCMAP0F77,plscmap0f77)
226
#define PLSCMAP0N FNAME(PLSCMAP0N,plscmap0n)
227
#define PLSCMAP1 FNAME(PLSCMAP1F77,plscmap1f77)
228
#define PLSCMAP1L FNAME(PLSCMAP1LF77,plscmap1lf77)
229
#define PLSCMAP1N FNAME(PLSCMAP1N,plscmap1n)
230
#define PLSCOL0 FNAME(PLSCOL0,plscol0)
231
#define PLSCOLBG FNAME(PLSCOLBG,plscolbg)
232
#define PLSCOLOR FNAME(PLSCOLOR,plscolor)
233
#define PLSCOMPRESSION FNAME(PLSCOMPRESSION,plscompression)
234
#define PLSDEV7 FNAME(PLSDEV7,plsdev7)
235
#define PLSDIDEV FNAME(PLSDIDEV,plsdidev)
236
#define PLSDIMAP FNAME(PLSDIMAP,plsdimap)
237
#define PLSDIORI FNAME(PLSDIORI,plsdiori)
238
#define PLSDIPLT FNAME(PLSDIPLT,plsdiplt)
239
#define PLSDIPLZ FNAME(PLSDIPLZ,plsdiplz)
240
#define PLSESC FNAME(PLSESC,plsesc)
241
#define PLSETMAPFORMC FNAME(PLSETMAPFORMC,plsetmapformc)
242
#define PLSETOPT7 FNAME(PLSETOPT7,plsetopt7)
243
#define PLSFAM FNAME(PLSFAM,plsfam)
244
#define PLSFNAM7 FNAME(PLSFNAM7,plsfnam7)
245
#define PLSHADE07 FNAME(PLSHADE07,plshade07)
246
#define PLSHADE17 FNAME(PLSHADE17,plshade17)
247
#define PLSHADE27 FNAME(PLSHADE27,plshade27)
248
#define PLSHADE7 FNAME(PLSHADE7,plshade7)
249
#define PLSHADES07 FNAME(PLSHADES07,plshades07)
250
#define PLSHADES17 FNAME(PLSHADES17,plshades17)
251
#define PLSHADES27 FNAME(PLSHADES27,plshades27)
252
#define PLSHADES7 FNAME(PLSHADES7,plshades7)
253
#define PLSMAJ FNAME(PLSMAJ,plsmaj)
254
#define PLSMEM FNAME(PLSMEM,plsmem)
255
#define PLSMIN FNAME(PLSMIN,plsmin)
256
#define PLSORI FNAME(PLSORI,plsori)
257
#define PLSPAGE FNAME(PLSPAGE,plspage)
258
#define PLSPAUSE FNAME(PLSPAUSEF77,plspausef77)
259
#define PLSSTRM FNAME(PLSSTRM,plsstrm)
260
#define PLSSUB FNAME(PLSSUB,plssub)
261
#define PLSSYM FNAME(PLSSYM,plssym)
262
#define PLSTAR FNAME(PLSTAR,plstar)
263
#define PLSTART7 FNAME(PLSTART7,plstart7)
264
#define PLSTRIPA FNAME(PLSTRIPA,plstripa)
265
#define PLSTRIPC FNAME(PLSTRIPCF77,plstripcf77)
266
#define PLSTRIPD FNAME(PLSTRIPD,plstripd)
267
#define PLSTYL FNAME(PLSTYL,plstyl)
268
#define PLSURF3D FNAME(PLSURF3DF77,plsurf3df77)
269
#define PLSVECT FNAME(PLSVECTF77,plsvectf77)
270
#define PLSVPA FNAME(PLSVPA,plsvpa)
271
#define PLSXAX FNAME(PLSXAX,plsxax)
272
#define PLSYAX FNAME(PLSYAX,plsyax)
273
#define PLSYM FNAME(PLSYMF77,plsymf77)
274
#define PLSZAX FNAME(PLSZAX,plszax)
275
#define PLTEXT FNAME(PLTEXT,pltext)
276
#define PLVASP FNAME(PLVASP,plvasp)
277
#define PLVEC07 FNAME(PLVEC07,plvec07)
278
#define PLVEC17 FNAME(PLVEC17,plvec17)
279
#define PLVEC27 FNAME(PLVEC27,plvec27)
280
#define PLVECT7 FNAME(PLVECT7,plvect7)
281
#define PLVPAS FNAME(PLVPAS,plvpas)
282
#define PLVPOR FNAME(PLVPOR,plvpor)
283
#define PLVSTA FNAME(PLVSTA,plvsta)
284
#define PLW3D FNAME(PLW3D,plw3d)
285
#define PLWID FNAME(PLWID,plwid)
286
#define PLWIND FNAME(PLWIND,plwind)
287
#define PLXORMOD FNAME(PLXORMODF77,plxormodf77)
289
#endif /* __PLSTUBS_H__ */