Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

libvbisam for VMS

162 views
Skip to first unread message

Arne Vajhøj

unread,
Mar 3, 2023, 2:21:01 PM3/3/23
to
https://www.vajhoej.dk/arne/vmsstuff/vbisam/

vbisam-2_0.tar-gz : original VBISAM 2.0 kit
vbisam-2_0-av.zip : my changes to make VBISAM 2.0 build and work work
(*) VMS

vbisam-2_0_1.tar-gz : original VBISAM 2.0.1 kit
vbisam-2_0_1-av.zip : my changes to make VBISAM 2.0.1 build and work (*)
on VMS

vbisam-2_1_1.zip : original VBISAM 2.1.1 kit
vbisam-2_1_1-av.zip : my changes to make VBISAM 2.1.1 build and work (*)
on VMS

*) Hacks:
- no locking in library only what RMS provides
- no check for if same file is opened twice with different name

vbi.zip : VBISAM extras
- VMS API callable from Cobol/Fortran/Pascal/Basic
- standalone utility to create simple VBISAM files
- JNI implementation for my Java ISAM library

Arne

JOUKJ

unread,
Mar 13, 2023, 7:25:48 AM3/13/23
to
Thanks for sharing this with us.

When compiling this stuff I got (apart from your specific directories) 2
problems

1) in isam.com scan_globals_for_option.com is calledbut missing in the
distribution. However I can guess what happens here.

2) when running @vms_vbisam.com I get:
spawn-tango-jj) @vms_vbisam.com

*buflen = isreclen;
..............^
%CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
at line number 78 in file
$DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisam
.c;1

*buflen = isreclen;
..............^
%CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
at line number 94 in file
$DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisam
.c;1

*buflen = isreclen;
..............^
%CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
at line number 100 in file
$DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisa
m.c;1

isreclen is a member of a structure but not a global variable. No idea
what is meant here.


Regards
Jouk

Arne Vajhøj

unread,
Mar 13, 2023, 8:32:42 AM3/13/23
to
On 3/13/2023 7:25 AM, JOUKJ wrote:
> Arne Vajhøj wrote:
>> https://www.vajhoej.dk/arne/vmsstuff/vbisam/
>>
>> vbisam-2_0.tar-gz   : original VBISAM 2.0 kit
>> vbisam-2_0-av.zip   : my changes to make VBISAM 2.0 build and work
>> work (*) VMS
>>
>> vbisam-2_0_1.tar-gz : original VBISAM 2.0.1 kit
>> vbisam-2_0_1-av.zip : my changes to make VBISAM 2.0.1 build and work
>> (*) on VMS
>>
>> vbisam-2_1_1.zip    : original VBISAM 2.1.1 kit
>> vbisam-2_1_1-av.zip : my changes to make VBISAM 2.1.1 build and work
>> (*) on VMS
>>
>> *) Hacks:
>> - no locking in library only what RMS provides
>> - no check for if same file is opened twice with different name
>>
>> vbi.zip             : VBISAM extras
>>                         - VMS API callable from
>> Cobol/Fortran/Pascal/Basic
>>                         - standalone utility to create simple VBISAM
>> files
>>                         - JNI implementation for my Java ISAM library

> When compiling this stuff I got (apart from your specific directories) 2
> problems
>
>  1) in isam.com scan_globals_for_option.com is calledbut missing in the
> distribution. However I can guess what happens here.

SCAN_GLOBALS_FOR_OPTION.COM and JAVA$BUILD_OPTION.EXE comes
with VMS Java.

I suppose I could leave the generated OPT file in the dist.

>  2) when running @vms_vbisam.com I get:
> spawn-tango-jj) @vms_vbisam.com
>
>     *buflen = isreclen;
> ..............^
> %CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
> at line number 78 in file
> $DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisam
> .c;1
>
>     *buflen = isreclen;
> ..............^
> %CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
> at line number 94 in file
> $DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisam
> .c;1
>
>     *buflen = isreclen;
> ..............^
> %CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
> at line number 100 in file
> $DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisa
> m.c;1
>
> isreclen is a member of a structure but not a global variable. No idea
> what is meant here.

VMS_VBISAM is intended to be build against 2.0 or 2.0.1 - to build
against 2.1.1 then one need to replace isreclen with
vb_get_rtd()->isreclen.

I should probably create 2 COM files or make something conditional.

It is a bad breaking change, but apperently someone did not like
the idea of exposing data directly from a shareable image
(DLL on Windows).

Thanks for the error report. I will update.

Arne


JOUKJ

unread,
Mar 13, 2023, 8:55:49 AM3/13/23
to
I can find the JAVA$BUILD_OPTION.EXE in my java directories, but not
SCAN_GLOBALS_FOR_OPTION.COM

Jouk

Arne Vajhøj

unread,
Mar 13, 2023, 9:12:41 AM3/13/23
to
On Alpha I have:

$ back/list
disk0:[vms$common.java$150.vms_demo]invoke_java_from_c_example.sav/sav
Listing of save set(s)

...

[JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]JAVA$BUILD_OPTION.EXE;1
14
5-MAY-1999 11:11

...

[JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]SCAN_GLOBALS_FOR_OPTION.COM;1
5
11-JAN-2001 10:57

Are you testing on Itanium?

I seem to recall that I could not find it on Itanium either
so I ended up just copying it from Alpha.

It is just a very simple wrapper around JAVA$BUILD_OPTION.EXE
to be able to handle wildcards in p1.

And JAVA$BUILD_OPTION.EXE just generate the OPT file with
the mangled names.

In this case:

!disk2:[arne.vbi]dk_vajhoej_vbisam_nativeapi.obj;1
case_sensitive=YES
SYMBOL_VECTOR=(Java_dk_vajhoej_vbisam_1427cj2$=PROCEDURE,-
Java_dk_vajhoej_vbisam_3eo58b6$=PROCEDURE,-
Java_dk_vajhoej_vbisam_1dree97$=PROCEDURE,-
Java_dk_vajhoej_vbisam_1q08s51$=PROCEDURE,-
Java_dk_vajhoej_vbisam_2rrbsmp$=PROCEDURE,-
Java_dk_vajhoej_vbisam_2pugmnt$=PROCEDURE)
case_sensitive=NO

Arne

JOUKJ

unread,
Mar 13, 2023, 9:36:31 AM3/13/23
to
Arne Vajhøj wrote:
> On Alpha I have:
>
> $ back/list
> disk0:[vms$common.java$150.vms_demo]invoke_java_from_c_example.sav/sav
> Listing of save set(s)
>
> ...
>
> [JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]JAVA$BUILD_OPTION.EXE;1
> 14 5-MAY-1999
> 11:11
>
> ...
>
> [JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]SCAN_GLOBALS_FOR_OPTION.COM;1
> 5
> 11-JAN-2001 10:57
>
> Are you testing on Itanium?
>

I did the test on Itanium

However on Alpha I have neither of the files. You seem to have another
version of java. The foleder on my Alpha is called JAVA$150

> I seem to recall that I could not find it on Itanium either
> so I ended up just copying it from Alpha.
>
> It is just a very simple wrapper around JAVA$BUILD_OPTION.EXE
> to be able to handle wildcards in p1.
>
> And JAVA$BUILD_OPTION.EXE just generate the OPT file with
> the mangled names.
>
> In this case:
>
> !disk2:[arne.vbi]dk_vajhoej_vbisam_nativeapi.obj;1
> case_sensitive=YES
> SYMBOL_VECTOR=(Java_dk_vajhoej_vbisam_1427cj2$=PROCEDURE,-
> Java_dk_vajhoej_vbisam_3eo58b6$=PROCEDURE,-
> Java_dk_vajhoej_vbisam_1dree97$=PROCEDURE,-
> Java_dk_vajhoej_vbisam_1q08s51$=PROCEDURE,-
> Java_dk_vajhoej_vbisam_2rrbsmp$=PROCEDURE,-
> Java_dk_vajhoej_vbisam_2pugmnt$=PROCEDURE)
> case_sensitive=NO
>

I can reproduce this on my Itanium just with JAVA$BUILD_OPTION.EXE


Jouk

Arne Vajhøj

unread,
Mar 13, 2023, 9:36:53 AM3/13/23
to
On 3/13/2023 8:32 AM, Arne Vajhøj wrote:
> On 3/13/2023 7:25 AM, JOUKJ wrote:
>>   1) in isam.com scan_globals_for_option.com is calledbut missing in
>> the distribution. However I can guess what happens here.
>
> SCAN_GLOBALS_FOR_OPTION.COM and JAVA$BUILD_OPTION.EXE comes
> with VMS Java.
>
> I suppose I could leave the generated OPT file in the dist.
>
>>   2) when running @vms_vbisam.com I get:
>> spawn-tango-jj) @vms_vbisam.com
>>
>>      *buflen = isreclen;
>> ..............^
>> %CC-E-UNDECLARED, In this statement, "isreclen" is not declared.
>> at line number 78 in file
>> $DISK16:[JOUKJ.public.vbisam.vbisam-2^.1^.1]vms_vbisam
>> .c;1

>> isreclen is a member of a structure but not a global variable. No idea
>> what is meant here.
>
> VMS_VBISAM is intended to be build against 2.0 or 2.0.1 - to build
> against 2.1.1 then one need to replace isreclen with
> vb_get_rtd()->isreclen.
>
> I should probably create 2 COM files or make something conditional.
>
> It is a bad breaking change, but apperently someone did not like
> the idea of exposing data directly from a shareable image
> (DLL on Windows).
>
> Thanks for the error report. I will update.

I have uploaded a new VBI.ZIP with some changes that intend
to solve issues.

Not elegant but hopefully sufficient for people to be able to figure
it out.

Example:

$ type vms_vbisam.com

$ cc/float=ieee/incl=disk1:[net.vbisam-2_0_1] vms_vbisam
$! cc/float=ieee/incl=disk1:[net.vbisam-2_1_1]/define="API21" vms_vbisam
$ exit

Arne


Arne Vajhøj

unread,
Mar 13, 2023, 9:39:40 AM3/13/23
to
On 3/13/2023 9:36 AM, JOUKJ wrote:
> Arne Vajhøj wrote:
>> On Alpha I have:
>>
>> $ back/list
>> disk0:[vms$common.java$150.vms_demo]invoke_java_from_c_example.sav/sav
>> Listing of save set(s)
>>
>> ...
>>
>> [JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]JAVA$BUILD_OPTION.EXE;1
>>                                                            14
>> 5-MAY-1999 11:11
>>
>> ...
>>
>> [JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]SCAN_GLOBALS_FOR_OPTION.COM;1
>>                                                             5
>> 11-JAN-2001 10:57
>>
>> Are you testing on Itanium?
>
> I did the test on Itanium

> However on Alpha I have neither of the files. You seem to have another
> version of java. The foleder on my Alpha is called JAVA$150

Yes.

You do not have a
disk0:[vms$common.java$150.vms_demo]invoke_java_from_c_example.sav ?

>> I seem to recall that I could not find it on Itanium either
>> so I ended up just copying it from Alpha.
>>
>> It is just a very simple wrapper around JAVA$BUILD_OPTION.EXE
>> to be able to handle wildcards in p1.
>>
>> And JAVA$BUILD_OPTION.EXE just generate the OPT file with
>> the mangled names.
>>
>> In this case:
>>
>> !disk2:[arne.vbi]dk_vajhoej_vbisam_nativeapi.obj;1
>> case_sensitive=YES
>> SYMBOL_VECTOR=(Java_dk_vajhoej_vbisam_1427cj2$=PROCEDURE,-
>>      Java_dk_vajhoej_vbisam_3eo58b6$=PROCEDURE,-
>>      Java_dk_vajhoej_vbisam_1dree97$=PROCEDURE,-
>>      Java_dk_vajhoej_vbisam_1q08s51$=PROCEDURE,-
>>      Java_dk_vajhoej_vbisam_2rrbsmp$=PROCEDURE,-
>>      Java_dk_vajhoej_vbisam_2pugmnt$=PROCEDURE)
>> case_sensitive=NO
>
> I can reproduce this on my Itanium just with JAVA$BUILD_OPTION.EXE

Yes.

Arne


JOUKJ

unread,
Mar 14, 2023, 4:08:50 AM3/14/23
to
Arne Vajhøj wrote:
> On 3/13/2023 9:36 AM, JOUKJ wrote:
>> Arne Vajhøj wrote:
>>> On Alpha I have:
>>>
>>> $ back/list
>>> disk0:[vms$common.java$150.vms_demo]invoke_java_from_c_example.sav/sav
>>> Listing of save set(s)
>>>
>>> ...
>>>
>>> [JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]JAVA$BUILD_OPTION.EXE;1
>>> 14
>>> 5-MAY-1999 11:11
>>>
>>> ...
>>>
>>> [JDK150_8_KIT.INVOKE_JAVA_FROM_C_EXAMPLE]SCAN_GLOBALS_FOR_OPTION.COM;1
>>> 5
>>> 11-JAN-2001 10:57
>>>
>>> Are you testing on Itanium?
>>
>> I did the test on Itanium
>
>> However on Alpha I have neither of the files. You seem to have another
>> version of java. The foleder on my Alpha is called JAVA$150
>
> Yes.
>
> You do not have a
> disk0:[vms$common.java$150.vms_demo]invoke_java_from_c_example.sav ?
>
It is in java$150 on Alpha & Itanium and in java$60 on Itanium, but not
in java$80 and Openjdk.

It is a saveset, so that is why my directory search did not find it.
0 new messages