Ravenports generated: 13 Mar 2020 23:41
[ravenports.git] / bucket_B9 / pgplot
1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
2
3 NAMEBASE=               pgplot
4 VERSION=                5.2.2
5 KEYWORDS=               graphics
6 VARIANTS=               standard
7 SDESC[standard]=        FORTRAN/C scientific graphic library
8 HOMEPAGE=               http://www.astro.caltech.edu/~tjp/pgplot/
9 CONTACT=                nobody
10
11 DOWNLOAD_GROUPS=        main
12 SITES[main]=            ftp://ftp.astro.caltech.edu/pub/pgplot/
13 DISTFILE[1]=            pgplot522.tar.gz:main
14 DF_INDEX=               1
15 SPKGS[standard]=        complete
16                         primary
17                         docs
18                         examples
19
20 OPTIONS_AVAILABLE=      none
21 OPTIONS_STANDARD=       none
22
23 USES=                   png shebangfix perl:build cmake fortran:examples
24 XORG_COMPONENTS=        x11 xt
25
26 DISTNAME=               pgplot
27
28 LICENSE=                CUSTOM1:primary
29 LICENSE_NAME=           CUSTOM1:"PGPLOT License"
30 LICENSE_FILE=           CUSTOM1:{{WRKSRC}}/copyright.notice
31 LICENSE_SCHEME=         solo
32
33 FPC_EQUIVALENT=         graphics/pgplot
34 SHEBANG_FILES=          makehtml
35                         maketex
36 SHEBANG_OLD_PERL=       /usr/local/bin/perl
37
38 CFLAGS=                 -Wno-implicit-function-declaration
39
40 post-patch:
41         ${REINPLACE_CMD} -e 's|png_ptr->jmpbuf|png_jmpbuf(png_ptr)|' \
42                 ${WRKSRC}/drivers/pndriv.c
43         ${REINPLACE_CMD} -e 's|/usr/local/pgplot|${PREFIX}/share/pgplot|g' \
44                 ${WRKSRC}/src/grgfil.f
45
46 post-install:
47         ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/pg*
48         ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/lib*.so
49         ${STRIP_CMD} ${STAGEDIR}${STD_EXAMPLESDIR}/*pgdemo*
50
51 post-extract:
52         ${CP} ${FILESDIR}/grexec.f ${WRKSRC}/sys/
53         ${CP} ${FILESDIR}/CMakeLists.txt ${WRKSRC}/
54 .for d in drivers pgdispd fonts src sys examples
55         ${CP} ${FILESDIR}/${d}_CMakeLists.txt ${WRKSRC}/${d}/CMakeLists.txt
56 .endfor
57
58 [FILE:408:descriptions/desc.primary]
59 PGPLOT is a Fortran subroutine package for drawing graphs on a variety
60 of display devices. For more details, see the manual ``PGPLOT Graphics
61 Subroutine Library'', available from T. J. Pearson.
62
63 The CPGPLOT library adds an intermediate level of wrapper functions
64 between C programs and the PGPLOT library. These functions hide the
65 system dependencies of calling PGPLOT behind a system independent
66 interface.
67
68
69 [FILE:95:distinfo]
70 a5799ff719a510d84d26df4ae7409ae61fe66477e3f1e8820422a9a4727a5be4      1197397 pgplot522.tar.gz
71
72
73 [FILE:164:manifests/plist.primary]
74 bin/
75  pgdisp
76  pgxwin_server
77 include/cpgplot.h
78 lib/
79  libcpgplot.a
80  libcpgplot.so
81  libcpgplot.so.5
82  libpgplot.a
83  libpgplot.so
84  libpgplot.so.5
85 share/pgplot/grfont.dat
86
87
88 [FILE:101:manifests/plist.docs]
89 share/doc/pgplot/
90  cpgplot.doc
91  pgplot-routines.tex
92  pgplot.doc
93  pgplot.html
94  readme.pgdisp
95  rgb.txt
96
97
98 [FILE:193:manifests/plist.examples]
99 share/examples/pgplot/
100  cpgdemo
101  pgdemo1
102  pgdemo10
103  pgdemo11
104  pgdemo12
105  pgdemo13
106  pgdemo14
107  pgdemo15
108  pgdemo16
109  pgdemo17
110  pgdemo2
111  pgdemo3
112  pgdemo4
113  pgdemo5
114  pgdemo6
115  pgdemo7
116  pgdemo8
117  pgdemo9
118
119
120 [FILE:1127:patches/patch-64bit-drivers]
121 --- drivers/gidriv.f.orig       1998-05-13 21:05:05.000000000 -0400
122 +++ drivers/gidriv.f    2011-12-07 16:57:04.000000000 -0500
123 @@ -78,7 +78,7 @@
124  C Note: for 64-bit operating systems, change the following 
125  C declaration to INTEGER*8:
126  C
127 -      INTEGER PIXMAP, WORK
128 +      INTEGER*8 PIXMAP, WORK
129  C
130        SAVE UNIT, IC, CTABLE, NPICT, MAXIDX, BX, BY, PIXMAP, FILENM
131        SAVE CDEFLT, STATE
132 --- drivers/ppdriv.f.orig       1998-05-13 21:04:29.000000000 -0400
133 +++ drivers/ppdriv.f    2011-12-07 16:57:39.000000000 -0500
134 @@ -68,7 +68,7 @@
135  C Note: for 64-bit operating systems, change the following 
136  C declaration to INTEGER*8:
137  C
138 -      INTEGER PIXMAP
139 +      INTEGER*8 PIXMAP
140  C
141        SAVE    UNIT, IC, CVAL, CTABLE, BX, BY, PIXMAP, NPICT, CDEFLT
142        SAVE    STATE
143 --- drivers/wddriv.f.orig       1998-05-13 21:03:53.000000000 -0400
144 +++ drivers/wddriv.f    2011-12-07 16:56:29.000000000 -0500
145 @@ -61,7 +61,7 @@
146  C Note: for 64-bit operating systems, change the following 
147  C declaration to INTEGER*8:
148  C
149 -      INTEGER PIXMAP
150 +      INTEGER*8 PIXMAP
151  C
152        SAVE UNIT, IC, CTABLE, NPICT, MAXIDX, BX, BY, PIXMAP, FILENM
153        SAVE CDEFLT, STATE
154
155
156 [FILE:283:patches/patch-pgdispd_proccom.c]
157 --- pgdispd/proccom.c.orig      Sat Sep 28 23:09:02 2002
158 +++ pgdispd/proccom.c   Sat Sep 28 23:09:27 2002
159 @@ -93,7 +93,7 @@
160  #include <sys/types.h>
161  #include <netinet/in.h>
162  
163 -#ifndef VMS
164 +#if !defined(VMS) && !defined(__FreeBSD__) && !defined(__DragonFly__)
165  #include <values.h>
166  #endif
167  
168
169
170 [FILE:314:files/CMakeLists.txt]
171 cmake_minimum_required(VERSION 3.16)
172 project(pgplot)
173 enable_language(Fortran)
174
175 SET(CMAKE_SKIP_BUILD_RPATH  TRUE)
176
177 add_subdirectory(drivers)
178 add_subdirectory(pgdispd)
179 add_subdirectory(fonts)
180 add_subdirectory(src)
181 add_subdirectory(sys)
182 add_subdirectory(examples)
183
184 install(FILES rgb.txt DESTINATION share/doc/pgplot)
185
186
187 [FILE:5373:files/drivers.list]
188 ! PGPLOT drivers.
189 !------------------------------------------------------------------------------
190 ! To configure PGPLOT, ensure that drivers you do not want are
191 ! commented out (place ! in column 1). N.B. Many device-drivers are
192 ! available on selected operating systems only.
193 !------------------------------------------------------------------------------
194 ! File       Code       Description                                Restrictions
195 ! BCDRIV 0 /BCANON    Canon Laser printer (bitmap version), landscape
196 ! CADRIV 0 /CANON     Canon Laser printer, LBP-8/A2, landscape
197 ! CCDRIV 0 /CCP       DEC LJ250 Color Companion printer
198 ! CWDRIV 0 /CW6320    Gould/Bryans Colourwriter 6320 pen plotter        Std F77
199 ! EPDRIV 0 /EPSON     Epson FX100 dot matrix printer
200 ! EXDRIV 1 /EXCL      Talaris/EXCL printers, landscape
201 ! EXDRIV 2 /EXCL      Talaris/EXCL printers, portrait
202 ! GCDRIV 0 /GENICOM   Genicom 4410 dot-matrix printer, landscape
203 !             Caution: use of GIDRIV may require a license from Unisys:
204   GIDRIV 1 /GIF       GIF-format file, landscape
205   GIDRIV 2 /VGIF      GIF-format file, portrait
206   GLDRIV 1 /HPGL      Hewlett-Packard HP-GL plotters, landscape         Std F77
207   GLDRIV 2 /VHPGL     Hewlett-Packard HP-GL plotters, portrait          Std F77
208 ! GODRIV 0 /GOC       GOC Sigma T5670 terminal                          VMS 
209 ! GVDRIV 0 /GVENICOM  Genicom 4410 dot-matrix printer, portrait
210   HGDRIV 0 /HPGL2     Hewlett-Packard graphics language
211 ! HIDRIV 0 /HIDMP     Houston Instruments HIDMP pen plotter
212 ! HJDRIV 0 /HJ        Hewlett-Packard Desk/Laserjet printer
213 ! HPDRIV 0 /HP7221    Hewlett-Packard HP7221 pen plotter                Std F77
214 ! IMDRIV 0 /IMPRESS   Imagen printers (Impress language), landscape
215 ! IRDRIV 0 /IRIS      SiliconGraphics Console                           SGI (C)
216 ! LADRIV 0 /LA50      Dec LA50 and other sixel printers
217 ! LJDRIV 0 /LJ        Hewlett-Packard LaserJet printers
218 ! LSDRIV 1 /LIPS2     Canon LaserShot printer (landscape)
219 ! LSDRIV 2 /VLIPS2    Canon LaserShot printer (portrait)
220 ! LNDRIV 0 /LN03      Dec LN03-PLUS Laser printer (landscape)           VMS
221 ! LVDRIV 0 /LVN03     Dec LN03-PLUS Laser printer (portrait)            VMS
222   LXDRIV 0 /LATEX     LaTeX picture environment
223 ! MFDRIV 0 /FILE      PGPLOT graphics metafile
224 ! NEDRIV 0 /NEXT      Computers running NeXTstep operating system
225   NUDRIV 0 /NULL      Null device (no output)                           Std F77
226   PPDRIV 1 /PPM       Portable Pixel Map file, landscape
227   PPDRIV 2 /VPPM      Portable PIxel Map file, portrait
228   PSDRIV 1 /PS        PostScript printers, monochrome, landscape        Std F77
229   PSDRIV 2 /VPS       Postscript printers, monochrome, portrait         Std F77
230   PSDRIV 3 /CPS       PostScript printers, color, landscape             Std F77
231   PSDRIV 4 /VCPS      PostScript printers, color, portrait              Std F77
232 ! PXDRIV 0 /PRINTRONI Printronix P300 or P600 dot-matrix printer
233 ! QMDRIV 1 /QMS       QUIC devices (QMS and Talaris), landscape         Std F77
234 ! QMDRIV 2 /VQMS      QUIC devices (QMS and Talaris), portrait          Std F77
235 ! SVDRIV 0 /SUNVIEW   Sun workstations running SunView                  SunOS C
236 ! TFDRIV 0 /TFILE     Tektronix-format disk file                        VMS
237 ! TODRIV 0 /TOSHIBA   Toshiba "3-in-one" printer, model P351
238 ! TTDRIV 1 /TEK4010   Tektronix 4006/4010 storage-tube terminal         Std F77
239 ! TTDRIV 2 /GF        GraphOn terminal                                  Std F77
240 ! TTDRIV 3 /RETRO     RetroGraphics terminal                            Std F77
241   TTDRIV 4 /GTERM     GTERM Tektronix terminal emulator                 Std F77
242   TTDRIV 5 /XTERM     XTERM Tektronix terminal emulator                 Std F77
243 ! TTDRIV 6 /ZSTEM     ZSTEM terminal emulator                           Std F77
244 ! TTDRIV 7 /V603      Visual 603 terminal                               Std F77
245 ! TTDRIV 8 /KRM3      Kermit 3 on IBM-PC                                Std F77
246   TTDRIV 9 /TK4100    Tektronix 4100-series terminals                   Std F77
247 ! TXDRIV 0 /TX        TeX PK Font Output files
248 ! VADRIV 0 /VCANON    Canon Laser printer, LBP-8/A2, portrait
249 ! VBDRIV 0 /VBCANON   Canon Laser printer (bitmap version), portrait
250 ! VIDRIV 0 /VIPRESS   Imagen printers (Impress language), portrait
251 ! VTDRIV 0 /VT125     Dec Regis terminals (VT125 etc.)                  Std F77
252   WDDRIV 1 /WD        X Window dump file, landscape
253   WDDRIV 2 /VWD       X Window dump file, portrait
254 ! WSDRIV 0 /WS        VAX workstations running VWS software             VMS
255   X2DRIV 0 /XDISP     PGDISP or FIGDISP server for X workstations       C
256   XWDRIV 1 /XWINDOW   Workstations running X Window System              C
257   XWDRIV 2 /XSERVE    Persistent window on X Window System              C
258 ! ZEDRIV 0 /ZETA      Zeta 8 Digital Plotter
259 !
260 ! The following drivers can only be used in PGPLOT installations on MS-DOS
261 ! systems with appropriate hardware and software. Do not select these 
262 ! on UNIX or VMS systems.
263 !
264 ! LHDRIV 0 /LH        IBM PCs and clones, Lahey F77 32-bit Fortran v5.0
265 ! MSDRIV 0 /MSOFT     IBM PCs and clones running Microsoft Fortran 5.0
266 ! SSDRIV 0 /SS        IBM PCs and clones, MS-DOS, Salford Software FTN
267 !
268 ! The following driver can only be used in PGPLOT installations on Acorn
269 ! Archimedes systems with appropriate hardware and software.
270 !
271 ! ACDRIV 0 /ARC       Acorn Archimedes computer
272 !
273 ! Selection of the XMOTIF driver causes a stub driver to be placed in
274 ! the main PGPLOT library. The real driver is placed in libXmPgplot.a.
275 ! Applications that need the Motif driver should link with libXmPgplot.a
276 ! before the PGPLOT library. This treatment means that only Motif
277 ! applications have to be linked with Motif libraries.
278 !
279 ! XMDRIV 0 /XMOTIF    Motif applications containing XmPgplot widgets.   C
280
281
282 [FILE:200:files/drivers_CMakeLists.txt]
283 set (prog pgxwin_server)
284
285 add_executable (${prog}
286         pgxwin_server.c
287 )
288
289 target_compile_definitions (${prog} PUBLIC PGDISP)
290 target_link_libraries (${prog} X11)
291
292 install (TARGETS ${prog} DESTINATION bin)
293
294
295 [FILE:478:files/examples_CMakeLists.txt]
296 foreach(N 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17)
297   add_executable(pgdemo${N} pgdemo${N}.f)
298   target_link_libraries(pgdemo${N} pgplot X11)
299   target_compile_options(pgdemo${N} PUBLIC -fno-backslash)
300   install(TARGETS pgdemo${N} DESTINATION share/examples/pgplot)
301 endforeach(N)
302
303 include_directories(${CMAKE_BINARY_DIR}/src)
304
305 add_executable(cpgdemo ../cpg/cpgdemo.c)
306 target_link_libraries(cpgdemo cpgplot pgplot X11 m)
307 install(TARGETS cpgdemo DESTINATION share/examples/pgplot)
308
309
310 [FILE:420:files/fonts_CMakeLists.txt]
311 set(outprefix grfont)
312 set(infile ${CMAKE_SOURCE_DIR}/fonts/${outprefix}.txt)
313 set(outfile ${CMAKE_CURRENT_BINARY_DIR}/${outprefix}.dat)
314
315 add_executable (pgpack pgpack.f)
316
317 add_custom_command(
318         OUTPUT ${outfile}
319         COMMAND pgpack < ${infile}
320         DEPENDS pgpack ${infile}
321         COMMENT "Generated ${outfile}"
322         VERBATIM
323 )
324
325 add_custom_target (generate_file ALL
326         DEPENDS ${outfile}
327 )
328
329 install (FILES ${outfile} DESTINATION share/pgplot)
330
331
332 [FILE:1806:files/grexec.f]
333 C*GREXEC -- PGPLOT device handler dispatch routine
334 C+
335       SUBROUTINE GREXEC(IDEV,IFUNC,RBUF,NBUF,CHR,LCHR)
336       INTEGER IDEV, IFUNC, NBUF, LCHR
337       REAL    RBUF(*)
338       CHARACTER*(*) CHR
339 C---
340       INTEGER NDEV
341       PARAMETER (NDEV=21)
342       CHARACTER*10 MSG
343 C---
344       GOTO(1,2,3,4,5,6,7,8,9,10,11,12,13,14,
345      +     15,16,17,18,19,20,21) IDEV
346       IF (IDEV.EQ.0) THEN
347           RBUF(1) = NDEV
348           NBUF = 1
349       ELSE
350           WRITE (MSG,'(I10)') IDEV
351           CALL GRWARN('Unknown device code in GREXEC: '//MSG)
352       END IF
353       RETURN
354 C---
355 1     CALL GIDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,1)
356       RETURN
357 2     CALL GIDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,2)
358       RETURN
359 3     CALL GLDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,1)
360       RETURN
361 4     CALL GLDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,2)
362       RETURN
363 5     CALL HGDRIV(IFUNC,RBUF,NBUF,CHR,LCHR)
364       RETURN
365 6     CALL LXDRIV(IFUNC,RBUF,NBUF,CHR,LCHR)
366       RETURN
367 7     CALL NUDRIV(IFUNC,RBUF,NBUF,CHR,LCHR)
368       RETURN
369 8     CALL PPDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,1)
370       RETURN
371 9     CALL PPDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,2)
372       RETURN
373 10    CALL PSDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,1)
374       RETURN
375 11    CALL PSDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,2)
376       RETURN
377 12    CALL PSDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,3)
378       RETURN
379 13    CALL PSDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,4)
380       RETURN
381 14    CALL TTDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,4)
382       RETURN
383 15    CALL TTDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,5)
384       RETURN
385 16    CALL TTDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,9)
386       RETURN
387 17    CALL WDDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,1)
388       RETURN
389 18    CALL WDDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,2)
390       RETURN
391 19    CALL X2DRIV(IFUNC,RBUF,NBUF,CHR,LCHR)
392       RETURN
393 20    CALL XWDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,1)
394       RETURN
395 21    CALL XWDRIV(IFUNC,RBUF,NBUF,CHR,LCHR,2)
396       RETURN
397 C
398       END
399
400
401 [FILE:498:files/pgdispd_CMakeLists.txt]
402 set (prog pgdisp)
403
404 add_executable (${prog}
405         cleanup.c
406         exposelgwin.c
407         figcurs.c
408         getcolors.c
409         getdata.c
410         getvisuals.c
411         handlexevent.c
412         initlgluts.c
413         initlgwin.c
414         initlock.c
415         initwmattr.c
416         mainloop.c
417         pgdisp.c
418         proccom.c
419         resdb.c
420         resizelgwin.c
421         returnbuf.c
422         updatelgtitle.c
423         waitevent.c
424 )
425
426 target_compile_definitions (${prog} PUBLIC PGDISP)
427 target_link_libraries (${prog} X11)
428
429 install(TARGETS ${prog} DESTINATION bin)
430 install(FILES aaaread.me
431         RENAME readme.pgdisp
432         DESTINATION share/doc/pgplot
433 )
434
435
436 [FILE:4124:files/src_CMakeLists.txt]
437 add_executable (pgbind ../cpg/pgbind.c)
438 target_compile_definitions (pgbind PUBLIC PG_PPU)
439
440 set(libsrcs
441         pgarro.f pgask.f pgband.f pgbbuf.f pgbeg.f pgbin.f pgbox.f
442         pgbox1.f pgcirc.f pgcl.f pgclos.f pgcn01.f pgcnsc.f pgconb.f pgconl.f
443         pgcons.f pgcont.f pgconx.f pgcp.f pgctab.f pgcurs.f pgdraw.f pgebuf.f
444         pgend.f pgenv.f pgeras.f pgerrb.f pgerrx.f pgerry.f pgetxt.f pgfunt.f
445         pgfunx.f pgfuny.f pggray.f pghi2d.f pghis1.f pghist.f pghtch.f
446         pgiden.f pgimag.f pginit.f pglab.f pglcur.f pgldev.f pglen.f pgline.f
447         pgmove.f pgmtxt.f pgncur.f pgnoto.f pgnpl.f pgnumb.f pgolin.f pgopen.f
448         pgpage.f pgpanl.f pgpap.f pgpixl.f pgpnts.f pgpoly.f pgpt.f pgptxt.f
449         pgqah.f pgqcf.f pgqch.f pgqci.f pgqcir.f pgqcol.f pgqcr.f pgqcs.f
450         pgqfs.f pgqhs.f pgqid.f pgqinf.f pgqitf.f pgqls.f pgqlw.f pgqpos.f
451         pgqtbg.f pgqtxt.f pgqvp.f pgqvsz.f pgqwin.f pgrect.f pgrnd.f pgrnge.f
452         pgsah.f pgsave.f pgscf.f pgsch.f pgsci.f pgscir.f pgscr.f pgscrn.f
453         pgsfs.f pgshls.f pgshs.f pgsitf.f pgslct.f pgsls.f pgslw.f pgstbg.f
454         pgsubp.f pgsvp.f pgswin.f pgtbox.f pgtext.f pgupdt.f pgvect.f pgvsiz.f
455         pgvstd.f pgvw.f pgwedg.f pgwnad.f pgadvance.f pgbegin.f pgcurse.f
456         pglabel.f pgmtext.f pgncurse.f pgpaper.f pgpoint.f pgptext.f pgvport.f
457         pgvsize.f pgvstand.f pgwindow.f pgaxis.f pgconf.f pgerr1.f pgpt1.f
458         pgqclp.f pgqdt.f pgqndt.f pgsclp.f pgscrl.f pgtick.f
459 )
460 set(src
461         cpgarro.c cpgask.c cpgband.c cpgbbuf.c cpgbeg.c cpgbin.c cpgbox.c
462         cpgcirc.c cpgclos.c cpgconb.c cpgconl.c cpgcons.c cpgcont.c cpgctab.c
463         cpgcurs.c cpgdraw.c cpgebuf.c cpgend.c cpgenv.c cpgeras.c cpgerrb.c
464         cpgerrx.c cpgerry.c cpgetxt.c cpggray.c cpghi2d.c cpghist.c cpgiden.c
465         cpgimag.c cpglab.c cpglcur.c cpgldev.c cpglen.c cpgline.c cpgmove.c
466         cpgmtxt.c cpgncur.c cpgnumb.c cpgolin.c cpgopen.c cpgpage.c cpgpanl.c
467         cpgpap.c cpgpixl.c cpgpnts.c cpgpoly.c cpgpt.c cpgptxt.c cpgqah.c
468         cpgqcf.c cpgqch.c cpgqci.c cpgqcir.c cpgqcol.c cpgqcr.c cpgqcs.c
469         cpgqfs.c cpgqhs.c cpgqid.c cpgqinf.c cpgqitf.c cpgqls.c cpgqlw.c
470         cpgqpos.c cpgqtbg.c cpgqtxt.c cpgqvp.c cpgqvsz.c cpgqwin.c cpgrect.c
471         cpgrnd.c cpgrnge.c cpgsah.c cpgsave.c cpgscf.c cpgsch.c cpgsci.c
472         cpgscir.c cpgscr.c cpgscrn.c cpgsfs.c cpgshls.c cpgshs.c cpgsitf.c
473         cpgslct.c cpgsls.c cpgslw.c cpgstbg.c cpgsubp.c cpgsvp.c cpgswin.c
474         cpgtbox.c cpgtext.c cpgunsa.c cpgupdt.c cpgvect.c cpgvsiz.c cpgvstd.c
475         cpgwedg.c cpgwnad.c cpgaxis.c cpgconf.c cpgerr1.c cpgpt1.c cpgqclp.c
476         cpgqdt.c cpgqndt.c cpgsclp.c cpgscrl.c cpgtick.c
477 )
478
479 macro(bind infile)
480 add_custom_command(
481         OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/c${infile}.c
482         COMMAND pgbind bsd -h -w ${CMAKE_SOURCE_DIR}/src/${infile}.f
483         DEPENDS pgbind ${CMAKE_SOURCE_DIR}/src/${infile}.f
484         VERBATIM
485 )
486 set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/c${infile}.c
487         PROPERTIES GENERATED true
488 )
489 endmacro(bind)
490
491 foreach(dossier ${src})
492         set(pathsrc ${pathsrc} ${CMAKE_CURRENT_BINARY_DIR}/${dossier})
493         set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/${dossier}
494                 PROPERTIES GENERATED true)
495 endforeach(dossier)
496
497 foreach(dossier ${libsrcs})
498         set(pathlibsrcs ${pathlibsrcs} ${CMAKE_SOURCE_DIR}/src/${dossier})
499 endforeach(dossier)
500
501 add_custom_command(
502         OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/cpgplot.h ${pathsrc}
503         COMMAND pgbind bsd -h -w ${pathlibsrcs}
504         DEPENDS pgbind ${pathlibsrcs}
505         VERBATIM
506 )
507
508 set_source_files_properties(${CMAKE_CURRENT_BINARY_DIR}/cpgplot.h
509         PROPERTIES GENERATED true)
510
511 add_library(plotobj OBJECT ${src})
512 set_property(TARGET plotobj PROPERTY POSITION_INDEPENDENT_CODE 1)
513
514 add_library(cpgplot SHARED $<TARGET_OBJECTS:plotobj>)
515 add_library(cpgplot_static ${src})
516
517 set_target_properties(cpgplot PROPERTIES VERSION 5)
518 set_target_properties(cpgplot PROPERTIES SOVERSION 5)
519 set_target_properties(cpgplot PROPERTIES PUBLIC_HEADER
520         ${CMAKE_CURRENT_BINARY_DIR}/cpgplot.h)
521
522 target_compile_definitions (cpgplot PUBLIC PG_PPU)
523 target_compile_definitions (cpgplot_static PUBLIC PG_PPU)
524
525 install(TARGETS cpgplot
526         LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
527         PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
528
529 install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libcpgplot_static.a
530         RENAME libcpgplot.a
531         DESTINATION lib)
532 install(FILES ../cpg/cpgplot.doc DESTINATION share/doc/pgplot)
533
534
535 [FILE:5920:files/sys_CMakeLists.txt]
536 set (S "${CMAKE_SOURCE_DIR}/src")
537 set (D "../drivers")
538 set (BSD "../sys_freebsd")
539
540 set(PG_ROUTINES
541         ${S}/pgarro.f
542         ${S}/pgask.f
543         ${S}/pgaxis.f
544         ${S}/pgaxlg.f
545         ${S}/pgband.f
546         ${S}/pgbbuf.f
547         ${S}/pgbeg.f
548         ${S}/pgbin.f
549         ${S}/pgbox.f
550         ${S}/pgbox1.f
551         ${S}/pgcirc.f
552         ${S}/pgcl.f
553         ${S}/pgclos.f
554         ${S}/pgcn01.f
555         ${S}/pgcnsc.f
556         ${S}/pgconb.f 
557         ${S}/pgconf.f 
558         ${S}/pgconl.f 
559         ${S}/pgcons.f 
560         ${S}/pgcont.f 
561         ${S}/pgconx.f 
562         ${S}/pgcp.f 
563         ${S}/pgctab.f
564         ${S}/pgcurs.f 
565         ${S}/pgdraw.f 
566         ${S}/pgebuf.f 
567         ${S}/pgend.f 
568         ${S}/pgenv.f 
569         ${S}/pgeras.f 
570         ${S}/pgerr1.f 
571         ${S}/pgerrb.f
572         ${S}/pgerrx.f 
573         ${S}/pgerry.f 
574         ${S}/pgetxt.f 
575         ${S}/pgfunt.f 
576         ${S}/pgfunx.f 
577         ${S}/pgfuny.f 
578         ${S}/pggray.f
579         ${S}/pghi2d.f 
580         ${S}/pghis1.f 
581         ${S}/pghist.f 
582         ${S}/pghtch.f 
583         ${S}/pgiden.f 
584         ${S}/pgimag.f 
585         ${S}/pginit.f 
586         ${S}/pglab.f
587         ${S}/pglcur.f 
588         ${S}/pgldev.f 
589         ${S}/pglen.f 
590         ${S}/pgline.f 
591         ${S}/pgmove.f 
592         ${S}/pgmtxt.f 
593         ${S}/pgncur.f 
594         ${S}/pgnoto.f
595         ${S}/pgnpl.f 
596         ${S}/pgnumb.f 
597         ${S}/pgolin.f 
598         ${S}/pgopen.f 
599         ${S}/pgpage.f 
600         ${S}/pgpanl.f 
601         ${S}/pgpap.f 
602         ${S}/pgpixl.f
603         ${S}/pgpnts.f 
604         ${S}/pgpoly.f 
605         ${S}/pgpt.f 
606         ${S}/pgpt1.f 
607         ${S}/pgptxt.f 
608         ${S}/pgqah.f 
609         ${S}/pgqcf.f 
610         ${S}/pgqch.f
611         ${S}/pgqci.f 
612         ${S}/pgqcir.f 
613         ${S}/pgqclp.f 
614         ${S}/pgqcol.f 
615         ${S}/pgqcr.f 
616         ${S}/pgqcs.f 
617         ${S}/pgqdt.f 
618         ${S}/pgqfs.f
619         ${S}/pgqhs.f 
620         ${S}/pgqid.f 
621         ${S}/pgqinf.f 
622         ${S}/pgqitf.f 
623         ${S}/pgqls.f 
624         ${S}/pgqlw.f 
625         ${S}/pgqndt.f 
626         ${S}/pgqpos.f
627         ${S}/pgqtbg.f 
628         ${S}/pgqtxt.f 
629         ${S}/pgqvp.f 
630         ${S}/pgqvsz.f 
631         ${S}/pgqwin.f 
632         ${S}/pgrect.f 
633         ${S}/pgrnd.f 
634         ${S}/pgrnge.f
635         ${S}/pgsah.f 
636         ${S}/pgsave.f 
637         ${S}/pgscf.f 
638         ${S}/pgsch.f 
639         ${S}/pgsci.f 
640         ${S}/pgscir.f 
641         ${S}/pgsclp.f 
642         ${S}/pgscr.f
643         ${S}/pgscrl.f 
644         ${S}/pgscrn.f 
645         ${S}/pgsfs.f 
646         ${S}/pgshls.f 
647         ${S}/pgshs.f 
648         ${S}/pgsitf.f 
649         ${S}/pgslct.f 
650         ${S}/pgsls.f
651         ${S}/pgslw.f 
652         ${S}/pgstbg.f 
653         ${S}/pgsubp.f 
654         ${S}/pgsvp.f 
655         ${S}/pgswin.f 
656         ${S}/pgtbox.f 
657         ${S}/pgtext.f 
658         ${S}/pgtick.f
659         ${S}/pgtikl.f 
660         ${S}/pgupdt.f 
661         ${S}/pgvect.f 
662         ${S}/pgvsiz.f 
663         ${S}/pgvstd.f 
664         ${S}/pgvw.f 
665         ${S}/pgwedg.f 
666         ${S}/pgwnad.f
667 )
668
669 set(PG_NON_STANDARD
670         ${S}/pgadvance.f 
671         ${S}/pgbegin.f 
672         ${S}/pgcurse.f 
673         ${S}/pglabel.f
674         ${S}/pgmtext.f 
675         ${S}/pgncurse.f 
676         ${S}/pgpaper.f 
677         ${S}/pgpoint.f 
678         ${S}/pgptext.f 
679         ${S}/pgvport.f 
680         ${S}/pgvsize.f
681         ${S}/pgvstand.f 
682         ${S}/pgwindow.f
683 )
684
685 set(GR_ROUTINES
686         ${S}/grarea.f 
687         ${S}/grbpic.f 
688         ${S}/grchsz.f 
689         ${S}/grclip.f 
690         ${S}/grclos.f 
691         ${S}/grclpl.f
692         ${S}/grctoi.f 
693         ${S}/grcurs.f 
694         ${S}/grdot0.f 
695         ${S}/grdot1.f 
696         ${S}/grdtyp.f 
697         ${S}/gresc.f 
698         ${S}/grepic.f 
699         ${S}/gretxt.f
700         ${S}/grfa.f 
701         ${S}/grfao.f 
702         ${S}/grgfil.f 
703         ${S}/grgray.f 
704         ${S}/grimg0.f 
705         ${S}/grimg1.f 
706         ${S}/grimg2.f 
707         ${S}/grimg3.f
708         ${S}/grinit.f 
709         ${S}/gritoc.f 
710         ${S}/grldev.f 
711         ${S}/grlen.f 
712         ${S}/grlin0.f 
713         ${S}/grlin1.f 
714         ${S}/grlin2.f 
715         ${S}/grlin3.f
716         ${S}/grlina.f 
717         ${S}/grmcur.f 
718         ${S}/grmker.f 
719         ${S}/grmova.f 
720         ${S}/grmsg.f 
721         ${S}/gropen.f 
722         ${S}/grpage.f 
723         ${S}/grpars.f
724         ${S}/grpixl.f 
725         ${S}/grpocl.f 
726         ${S}/grprom.f 
727         ${S}/grpxpo.f 
728         ${S}/grpxps.f 
729         ${S}/grpxpx.f 
730         ${S}/grpxre.f
731         ${S}/grqcap.f 
732         ${S}/grqci.f 
733         ${S}/grqcol.f 
734         ${S}/grqcr.f 
735         ${S}/grqdev.f 
736         ${S}/grqdt.f 
737         ${S}/grqfnt.f 
738         ${S}/grqls.f
739         ${S}/grqlw.f 
740         ${S}/grqpos.f 
741         ${S}/grqtxt.f 
742         ${S}/grqtyp.f 
743         ${S}/grquit.f 
744         ${S}/grrec0.f 
745         ${S}/grrect.f 
746         ${S}/grsci.f
747         ${S}/grscr.f 
748         ${S}/grsetc.f 
749         ${S}/grscrl.f 
750         ${S}/grsetc.f 
751         ${S}/grsets.f 
752         ${S}/grsfnt.f 
753         ${S}/grsize.f 
754         ${S}/grskpb.f
755         ${S}/grslct.f 
756         ${S}/grsls.f 
757         ${S}/grslw.f 
758         ${S}/grsyds.f 
759         ${S}/grsymk.f 
760         ${S}/grsyxd.f 
761         ${S}/grterm.f 
762         ${S}/grtext.f
763         ${S}/grtoup.f 
764         ${S}/grtrim.f 
765         ${S}/grtrn0.f 
766         ${S}/grtxy0.f 
767         ${S}/grvct0.f 
768         ${S}/grwarn.f 
769         ${S}/grxhls.f
770         ${S}/grxrgb.f
771 )
772
773 set(DRIVERS
774         ${D}/gidriv.f
775         ${D}/gldriv.f
776         ${D}/hgdriv.f
777         ${D}/lxdriv.f
778         ${D}/nudriv.f
779         ${D}/ppdriv.f
780         ${D}/psdriv.f
781         ${D}/ttdriv.f
782         ${D}/wddriv.f
783         ${D}/x2driv.c
784         ${D}/figdisp_comm.c
785         ${D}/xwdriv.c
786         ${D}/cgdriv.c
787         ${D}/pndriv.c
788         ${D}/xadriv.c
789 )
790
791 set(SYSTEM_ROUTINES
792         grdate.c grfileio.c grflun.f grgcom.f grgenv.f
793         grgetc.c grglun.f grgmem.c grgmsg.f grlgtr.f groptx.f grsy00.f
794         grtermio.c grtrml.f grtter.f gruser.c
795 )
796
797 IF(CMAKE_SYSTEM_NAME MATCHES "(FreeBSD|DragonFly)")
798         set(OS_SPECIFIC ${BSD}/iand.c)
799 ENDIF()
800
801 set(SRCS 
802         ${PG_ROUTINES}
803         ${PG_NON_STANDARD}
804         ${GR_ROUTINES}
805         ${SYSTEM_ROUTINES}
806         ${DRIVERS}
807         ${OS_SPECIFIC}
808         grexec.f        # provided
809 )
810
811 add_library(fplotobj OBJECT ${SRCS})
812 set_property(TARGET fplotobj PROPERTY POSITION_INDEPENDENT_CODE 1)
813
814 add_library(pgplot SHARED $<TARGET_OBJECTS:fplotobj>)
815 add_library(pgplot_static ${SRCS})
816
817 set_target_properties(pgplot PROPERTIES VERSION 5)
818 set_target_properties(pgplot PROPERTIES SOVERSION 5)
819
820 target_compile_definitions (fplotobj PUBLIC PG_PPU)
821 target_compile_definitions (pgplot_static PUBLIC PG_PPU)
822
823 target_link_libraries (pgplot png)
824
825 install(TARGETS pgplot
826         LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
827         PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
828
829 install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libpgplot_static.a
830         RENAME libpgplot.a
831         DESTINATION lib)
832
833 set (out_doc ${CMAKE_CURRENT_BINARY_DIR}/pgplot.doc)
834 set (out_htm ${CMAKE_CURRENT_BINARY_DIR}/pgplot.html)
835 set (out_tex ${CMAKE_CURRENT_BINARY_DIR}/pgplot-routines.tex)
836
837 add_custom_command(
838         OUTPUT ${out_doc}
839         COMMAND ${CMAKE_SOURCE_DIR}/makedoc ${PG_ROUTINES} ${PG_NON_STANDARD} > ${out_doc}
840         DEPENDS ${PG_ROUTINES} ${PG_NON_STANDARD}
841         COMMENT "Generated ${out_doc}"
842         VERBATIM
843 )
844
845 add_custom_command(
846         OUTPUT ${out_htm}
847         COMMAND ${CMAKE_SOURCE_DIR}/makehtml ${PG_ROUTINES} ${PG_NON_STANDARD} > ${out_htm}
848         DEPENDS ${PG_ROUTINES} ${PG_NON_STANDARD}
849         COMMENT "Generated ${out_htm}"
850         VERBATIM
851 )
852
853 add_custom_command(
854         OUTPUT ${out_tex}
855         COMMAND ${CMAKE_SOURCE_DIR}/maketex ${PG_ROUTINES} ${PG_NON_STANDARD} > ${out_tex}
856         DEPENDS ${PG_ROUTINES} ${PG_NON_STANDARD}
857         COMMENT "Generated ${out_tex}"
858         VERBATIM
859 )
860
861 add_custom_target(gen_docs ALL
862         DEPENDS ${out_doc} ${out_htm} ${out_tex}
863 )
864
865 install(FILES ${out_doc} ${out_htm} ${out_tex}
866         DESTINATION share/doc/pgplot)
867