Developing freeware
Document Sample


Developing freeware
Fekko Stubbe
Kadaster
OpenVMS TUD 11 oktober 2006
Agenda
• Introduction
• Kadaster changes
• Maintaining freeware
• DIX
• FSHELP
• AUTO
• Questions?
OpenVMS TUD 11 oktober 2006
Fekko Stubbe
• 85-90 : Designer/developer on VAX-VMS
in a hospital.
• 90-96 : System management VAX-VMS
Fokker
• 96-now : System management VMS
Kadaster
OpenVMS TUD 11 oktober 2006
Kadaster changes
• 1999 : Starting point
1. 15 sites, each with 1 triplehost VAX cluster, 1 single host
VAX (all using DSSI) and one alpha server with SCSI.
2. 2 central sites with 2 VAX-VMS clusters (dssi)
• 2001: Migration from Vax to Alpha via mixed clusters.
Afterwards still 17 sites, with 17 Alpha servers still using
DSSI.
• 2002: Replacement of DSSI storage by SCSI.
• 2003: Centralization of 17 sites to 1. Still 17 systems.
OpenVMS TUD 11 oktober 2006
Kadaster changes part 2
• 2004: Creation of new central system (GS1280) ,
attached to SAN disks (EVA). All users logged in
central system and were (transparently) forwarded
by the menu system to the correct system.
• 2004: Consolidation of the 17 Alpha servers to the
central system (the GS1280 6 cpu)
• No user downtime during production time.
OpenVMS TUD 11 oktober 2006
Used tooling
• Centralized login. Users are transparently
connected to the correct system
(lgi_callout).
• Centralized printing. Like DQS.
• Class scheduling
Application/location/mode
• Watchdog.
OpenVMS TUD 11 oktober 2006
Freeware
• Development since 1990.
• Is also used internally (but not for
production).
• First on VAX.
• From 2002 Vax/Alpha
• From 2005 Vax/Alpha/IA64
OpenVMS TUD 11 oktober 2006
Why
• It's fun
• Lets you understand VMS better
• Gets you in touch with other VMS people
OpenVMS TUD 11 oktober 2006
Development system(s)
• Development on Alpha.
• Alpha 800 at home
• Triple architecture cluster at Ton's place.
• Website for freeware
http://www.oooovms.dyndns.org/ and the
normal VMS freeware site
OpenVMS TUD 11 oktober 2006
OpenVMS TUD 11 oktober 2006
OpenVMS TUD 11 oktober 2006
Targets
• Development in Fortran (ABCDEF rule).
• Development for all platforms.
• Try to be VMS version independent
• Single code stream.
• Kits with all sources, exe's and objects.
• Result : ZIP file of a backup saveset, so the DIX_051.ZIP
contains the DIX_051.BCK saveset, that contains all
sources/objects/exes for all architectures.
OpenVMS TUD 11 oktober 2006
Problems
• Alpha version 8.2, Vax 7.3, IA64 8.2-1
• Fortran differences
• VMS version differences
• Architectural differences
OpenVMS TUD 11 oktober 2006
Fortran differences
• On VAX only F77 compiler.
• On Alpha F77 and F90.
• On IA64 only F90.
• The F90 compiler also accepts F77 code.
• So we must use F77 language for the freeware, on VAX
the F77 compiler is used, on Alpha/IA64 the F90 compiler
is used (with F77 code).
• But, F77 has no conditional compilation.
OpenVMS TUD 11 oktober 2006
VMS version differences
• VAX on 7.3, so all later functionality is not
there, so this functionality can either not be
used, or must be "conditionalized"
• F.e. floating point conversion routines
OpenVMS TUD 11 oktober 2006
Architecture differences
• VAX : No NAML block, no ODS-5.
• VAX : No integer*8 format.
• IA64: different FP format (IEEE), so f.e. the
LIB$WAIT(f_float).
• IA64: Completely different object/binary
format (make tool).
• IA64: EXTERNAL for data. Via CDEC$
attributes (not on F77 FORTRAN)
OpenVMS TUD 11 oktober 2006
Lib$wait example
• LIB$WAIT(1.0,[float_format]), default format is
F_FLOAT
• VAX/ALPHA generate f_float by default, so we need not
specify float_format
• IA64 generates S_float (IEEE), so we need to specify
lib$wait(1.0,LIB$K_IEEE_S)
• It is not possible to use one source for all platforms
• Why not : LIB$WAIT(1.0,LIB$K_FLOAT_DEFAULT)
OpenVMS TUD 11 oktober 2006
Porting issues
• VAX to Alpha port: It was 6 years ago,
but I do not recall any (major) problems.
• Alpha to IA64 port.
1. Floating point (lib$wait)
2. EXTERNAL issue
3. Different object/exe format (make tool)
OpenVMS TUD 11 oktober 2006
Make tool
• Make tool with knowledge about platforms.
• Defined symbols that can be used in make_file
1. Architecture : vax/alpha/ia64
2. Architecture_vax : not_vax/vax
3. Architecture_alpha : not_alpha/alpha
4. Architecture_ia64: not_ia64/ia64.
Rules : dix_symbol_library_'architecture_vax'.for will be expanded to
dix_symbol_library_vax.for on vax and
dix_symbol_library_not_vax.for on alpha/ia64
OpenVMS TUD 11 oktober 2006
Results
• DIX : Common code 24 files/55000 lines,
platform specific 5 files,600 lines
• FSHELP:Common code 15 files/15000
lines, platform specific 3 files/2000 lines.
• AUTO, DCL auto command completion
with help.
• REGEDIT, a registry editor (using SMG)
OpenVMS TUD 11 oktober 2006
Building procedure
• On ton's triple architecture cluster.
• Clear the whole directory tree [.DIX...]
• Backup all sources to [.dix] and rename to ;1.
• Submit 3 batchjobs on the 3 machines. These jobs create
the objects in [.dix.'arch'] and the dix_'arch'.exe
• Wait for batchjobs
• Check the batchjobs for errors.
• Backup the whole tree to a backup save set.
• Zip the backup file=>.zip file
OpenVMS TUD 11 oktober 2006
Building times DIX
• Alpha 800/500 CPU 8:12, Elaps 8:26
• Alpha DS10L/667 CPU 2:20, Elaps 2:57
• Personal Alpha Cpu 1:34:00, Elaps 1:36:00
• VAX 4108 40 Vups Cpu 2:41 Elaps 3:27
• IA64 1620/1.3Ghz Cpu 1:29 Elaps 2:41
•
OpenVMS TUD 11 oktober 2006
Freeware DIX
• DIX is a record viewer/modifier.
• Works in screen mode (SMG and DECW(soon in the 6.0
version)), line mode (also in batch) and dump mode.
• Has record descriptions, and you can define descriptions
for your own files (ala DTR).
• Has a very powerful scripting language.
• Has a powerful (multiple) record search
• It uses RMS or internal routines emulating RMS (also for
indexed file, but READONLY).
OpenVMS TUD 11 oktober 2006
Example raw dump/smg
File :KXSYS_DISK:[VMS_COMMON.SYSEXE]SYSUAF.DAT;3 Var/Idx
Recsiz:644 Offs:0.0 Data:Hex Recnr:1 RFA:(4,29)
F E D C B A 9 8 7 6 5 4 3 2 1 0 0123456789ABCDEF
20202054 50495243 53243141 00000101 ....A1$SCRIPT 0
20202020 20202020 20202020 20202020 16
00000000 00000000 000D0003 20202020 ............ 32
20202020 20202020 20202020 00000000 .... 48
20202020 20202020 20202020 20202020 64
68746E65 54206572 646E4117 20202020 .Andre Tenth 80
20202020 6E656472 6F6F4E6E 6176666F ofvanNoorden 96
53544E55 4F434341 5F31410C 20202020 .A1_ACCOUNTS 112
20202020 20202020 20202020 2020203A : 128
OpenVMS TUD 11 oktober 2006
Example des dump/smg
File :KXSYS_DISK:[VMS_COMMON.SYSEXE]SYSUAF.DAT;3 Var/Idx
Recsiz:644 Offs:0.0 Data:Norm Recnr:1 RFA:(4,29)
Des file :DSA50:[PBO.SUPP_VMS.UTILITIES]DIX_DES.TLB;109(SYSUAF)
0.0.UAF$B_RTYPE .1
1.0.UAF$B_VERSION .1
2.0.UAF$W_USRDATOFF .0
4.0.UAF$T_USERNAME .A1$SCRIPT
36.0.UAF$W_MEM .000003
38.0.UAF$W_GRP .000015
36.0.UAF$L_UIC .[A1$SCRIPT] = [15,3]
40.0.UAF$L_SUB_ID .0
OpenVMS TUD 11 oktober 2006
open programs_top:[dix.regres]sysuaf.work/mod
nmod = 0
nfnd = 0
on error goto done
read /GE="TEST"
loop:
nfnd = nfnd + 1
echo "Found user ''uaf$t_username'"
if (f$matchwild(uaf$t_username,"*TEST*")) goto next
if (uaf$l_bytlm < 50000) goto next
deposit uaf$l_bytlm='uaf$l_bytlm + 1000'
nmod = nmod + 1
update/quiet
echo "Updated ''uaf$t_username' to ''uaf$l_bytlm'"
next:
next record
goto loop
done:
echo "status = ''$status'"
echo "Found ''nfnd' users , modified ''nmod' users"
close sysuaf
OpenVMS TUD 11 oktober 2006
DIX Record search
• Dix/file sysuaf 10000/field=*_bytl*/mat=ge
• Dix/file filename str1 str2/disp
• Dix/file filename *str1*xy*/mat=wild
• Dix/file sysuaf 1000/field=*enq*/mat=le,
200/field=*fillm/mat=ge
OpenVMS TUD 11 oktober 2006
Freeware FSHELP
• FSHELP is a helpfile viewer.
• But also .TLB,/.OLB/.MLB
• Can use see-also's (if in the help source).
• Can search through the help file(s) for a string.
• Can load the help file(s) in memory (and make the
searches faster)
• You can add your own language (now english,
dutch and fries) (you do not need a compiler).
OpenVMS TUD 11 oktober 2006
Example FSHELP(fshelp copy)
Library:SYS$COMMON:[SYSHLP]HELPLIB.HLB;5 Line 1-14 of 14(LD)
Topic :COPY
Creates a new file from one or more existing files. The COPY
command can do the following:
o Copy an input file to an output file.
o Concatenate two or more input files into a single output file.
o Copy a group of input files to a group of output files.
Format
COPY input-filespec[,...] output-filespec
,,,,,,,,,,,,,,,,,,,,,,,,,,,,,Nr 1 of 28 help
topics,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
Parameters
Qualifiers
/ALLOCATION /BACKUP /BEFORE /BLOCK_SIZE /BY_OWNER
/CONCATENATE /CONFIRM /CONTIGUOUS /CREATED /EXCLUDE /EXPIRED
/EXTENSION /LOG /MODIFIED /OVERLAY /PROTECTION
OpenVMS TUD 11 oktober 2006
FSHELP /TEXT
Library:TXT:SYS$COMMON:[SYSLIB]FORSYSDEF.TLB;1 Line 1-7 of 7(D)
Topic :
Directory of Text library SYS$COMMON:[SYSLIB]FORSYSDEF.TLB;1
Creation date: 1-DEC-2000 10:08:24 Creator: Librarian A09-22
Revision date: 1-DEC-2000 10:08:27 Library format: 3.0
Number of modules: 298 Max. key length: 39
Other entries: 0 Preallocated index blocks: 43
Recoverable deleted blocks: 0 Total index blocks used: 14
Max. Number history records: 0 Library history records: 0
,,,,,,,,,,,,,,,,,,,,,,,,,,,,Nr 1 of 298 help
topics,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
$ACCDEF $ACEDEF $ACLDEF $ACMEDEF $ACMEMSGDEF $ACMEVMSDEF
$ACRDEF $AFRDEF $AGNDEF $ALPHADEF $ARGDEF $ARMDEF $ATRDEF $BRKDEF
$CAPDEF $CBODEF $CHFDEF $CHKPNTDEF $CHPDEF $CIADEF $CLIDEF
$CLIMSGDEF $CLISERVDEF $CLIVERBDEF $CLSDEF
$CLUEVTDEF $CMBDEF $CONVDEF $CONVMSGDEF $CQUALDEF $CRDEF
OpenVMS TUD 11 oktober 2006
Freeware AUTO
• AUTO is a command line completion tool
• Uses the CLD table in p1 space for parameter/qualifier and
their types and values.
• Also symbols, like mydel :=delete/confirm
• Also cld tables in images
• Interfaces to HELP for command/qual help
• Symbols that translate to @xxx follow the standard syntax,
but you can (re)define your own definition for the
parameter(s)
OpenVMS TUD 11 oktober 2006
Related docs
Get documents about "