1748266 Members
3321 Online
108760 Solutions
New Discussion

Re: libxml building

 
SOLVED
Go to solution
AlexanderM
Advisor

libxml building

Hello to everybody.

  • Xml parser is required for using with c.
  • I have not admin privilegies => standard solution is not appropriate.
  • I've choose libxml
  • Sourses include .vms directory with .com file

The first problem is: how to run .com file.

I've tried to use @ for example @filename.com, but it has not worked.

19 REPLIES 19
AlexanderM
Advisor

Re: libxml building

  • error
> @build_libxml.com
%DCL-W-UNDSYM, undefined symbol - check validity and spelling
\\
%DCL-W-NOCOMD, no command on line - reenter with alphabetic first character
%DCL-W-UNDSYM, undefined symbol - check validity and spelling
\\
%DCL-W-UNDSYM, undefined symbol - check validity and spelling
\WHOAMI\
%RMS-F-SYN, file specification syntax error
 
  • Readme file contains the next: 

- File attributes.  Having downloaded essentially a Unix distribution, some
  of the file attributes weren't correct... especially those in the [.VMS]
  subdirectory.  In EDT you could see line feeds and carriage returns as
  <LF><CR> etc.  To correct this use the command

    $ set file <filespec> /attr=rfm=stm

 

but this command does not work too:

set file build_libxml.com/attr=rfm=asmd
%DCL-W-IVKEYW, unrecognized keyword - check validity and spelling
\ASMD\

Re: libxml building

The correct syntax of the "Set file /attrib" OpenVMS command is :

 

$ Set File /Attrib=(rfm:stm)  <filespec>

 

The following table lists the keywords and the relationship to both ACP-QIO and OpenVMS RMS File attributes:

 

Keyword            ACP-QIO File Attribute                                OpenVMS RMS FileAttribute

RFM:FIX             FAT$V_RTYPE=FAT$C_FIXED                    FAB$B_RFM=FAB$C_FIX
RFM:STM           FAT$V_RTYPE=FAT$C_STREAM               FAB$B_RFM=FAB$C_STM         <==
RFM:STMCR      FAT$V_RTYPE=FAT$C_STREAMCR          FAB$B_RFM=FAB$C_STMCR
RFM:STMLF      FAT$V_RTYPE=FAT$C_STREAMLF           FAB$B_RFM=FAB$C_STMLF
RFM:UDF           FAT$V_RTYPE=FAT$C_UNDEFINED         FAB$B_RFM=FAB$C_UDF
RFM:VAR          FAT$V_RTYPE=FAT$C_VARIABLE             FAB$B_RFM=FAB$C_VAR
RFM:VFC           FAT$V_RTYPE=FAT$C_VFC                        FAB$B_RFM=FAB$C_VFC

 

RFM:ASMD is not a valid file attibuite under OpenVMS.

 

As reported by the README, you should modify the file attribute of all vms specific files (only ascii format not binary), for example :

 

$ Set File/Attrib=RFM:STM [.vms]*.c,[.vms...]*.h,[.vms...]*.txt

 

But I don't exclude that you should modify also the file attribuite of other Source Codes of the libmxl distribution kit. Take a look into the libxml.com command procedure.

 

>>> I have not admin privilegies => standard solution is not appropriate

 

I suspect that your experiment will require also the "system" privileges...

 

Good luck,

/Maurizio

[ I am a HPE Employee and an OpenVMS Ambassador ]
AlexanderM
Advisor

Re: libxml building

Thanks)

AlexanderM
Advisor

Re: libxml building

Is helps, but not compleatly. I've got an error in the next fragment of com file:

 
$whoami = f$parse(f$environment("PROCEDURE"),,,,"NO_CONCEAL")
$   procdir = f$parse(whoami,,,"DEVICE") + f$parse(whoami,,,"DIRECTORY")
$   set default 'procdir'
 

Is the 'smth'  the equivalent of $smth in linux i.e. is this an getting of variable smth value?

Re: libxml building

Can you post the error that you observe when you run the command file ?

 

Your dcl code runs error free on my system (I inserted few lines only for the troubleshooting purposes)  :

 

$!  Test_alexander.com

$!
$   whoami  = f$parse(f$environment("PROCEDURE"),,,,"NO_CONCEAL")
$   write sys$output " "
$   write sys$output "whoami symbol = ''whoami'"
$   write sys$output " "
$   procdir = f$parse(whoami,,,"DEVICE") + f$parse(whoami,,,"DIRECTORY")
$   write sys$output " "
$   write sys$output "procdir symbol = ''procdir'"
$   write sys$output " "
$   set default 'procdir'
$!
$   Exit

 

$ sho def

    $2$DKA100:[000000]

 

$ @test_alexander

 

whoami symbol = $2$DKA100:[000000]test_alexander.com;1


procdir symbol = $2$DKA100:[000000]

 

$ sho def

    $2$DKA100:[000000]

 

Regards,

/Maurizio

[ I am a HPE Employee and an OpenVMS Ambassador ]
AlexanderM
Advisor

Re: libxml building

Sometimes I forget that there are no telepathists on this forum).

System: OpenVMS ALpha 8.3

The script is (I've inserted WRITE SYS$OUTPUT "tag" to locate the error):

$! BUILD_LIBXML.COM
$!
$! Build the LIBXML library
$!
$! Arguments:
$!
$!       "DEBUG"  - build everything in debug
$!
$! This procedure creates an object library XML_LIBDIR:LIBXML.OLB directory.
$! After the library is built, you can link LIBXML routines into
$! your code with the command
$!
$!      $ LINK your_modules,XML_LIBDIR:LIBXML.OLB/LIBRARY
$!
$! Change History
$! --------------
$! Command file author : John A Fotheringham (jaf@jafsoft.com)
$! Update history      : 19 March 2008  Tycho Hilhorst
$!                       - added module schematron.c (prevent xmllint errors)
$!                       - added /DEF and /INCLUDE options to cc_opts to tell
$!                         config.h is available, and where to find it
$!                     : 13 October 2003        Craig Berry (craigberry@mac.com)
$!                       more new module additions
$!                     : 25 April 2003          Craig Berry (craigberry@mac.com)
$!                       added xmlreader.c and relaxng.c to source list
$!                      : 28 September 2002       Craig Berry (craigberry@mac.com)
$!                       updated to work with current sources
$!                       miscellaneous enhancements to build process
$!
$!- configuration -------------------------------------------------------------
$!
$!- compile command.  If p1="nowarn" suppress the expected warning types
$!
$   cc_opts = "/DEF=HAVE_CONFIG_H/NAMES=(SHORTENED)/FLOAT=IEEE/IEEE_MODE=DENORM_RESULTS/INCLUDE=xml_srcdir"
$!
$   if p1.eqs."DEBUG" .or. p2.eqs."DEBUG"
$   then
$     debug = "Y"
$     cc_command = "CC''cc_opts'/DEBUG/NOOPTIMIZE/LIST/SHOW=ALL"
$   else
$     debug = "N"
$     cc_command = "CC''cc_opts'"
$   endif
$!
$!- list of sources to be built into the LIBXML library.  Compare this list
$!  to the definition of "libxml2_la_SOURCES" in the file MAKEFILE.IN.
$!  Currently this definition includes the list WITH_TRIO_SOURCES_TRUE
$!
$   sources = "SAX.c entities.c encoding.c error.c parserInternals.c"
$   sources = sources + " parser.c tree.c hash.c list.c xmlIO.c xmlmemory.c uri.c"
$   sources = sources + " valid.c xlink.c HTMLparser.c HTMLtree.c debugXML.c xpath.c"
$   sources = sources + " xpointer.c xinclude.c nanohttp.c nanoftp.c DOCBparser.c"
$   sources = sources + " catalog.c globals.c threads.c c14n.c xmlstring.c"
$   sources = sources + " xmlregexp.c xmlschemas.c xmlschemastypes.c xmlunicode.c"
$   sources = sources + " triostr.c trio.c xmlreader.c relaxng.c dict.c SAX2.c"
$   sources = sources + " xmlwriter.c legacy.c chvalid.c pattern.c xmlsave.c"
$   sources = sources + " schematron.c"
$!
$!- list of main modules to compile and link.  Compare this list to the
$!  definition of bin_PROGRAMS in MAKEFILE.IN
$!
$   bin_progs = "xmllint xmlcatalog"
$!
$!- list of test modules to compile and link.  Compare this list to the
$!  definition of noinst_PROGRAMS in MAKEFILE.
$!
$   noinst_PROGRAMS = "testSchemas testRelax testSAX testHTML testXPath testURI " -
                + "testThreads testC14N testAutomata testRegexp testReader"
$!
$!- set up build logicals -----------------------------------------------------\
$!
$!
$!- start from where the procedure is in case it's submitted in batch ----------\
$!
$   whoami = f$parse(f$environment("PROCEDURE"),,,,"NO_CONCEAL")
$   procdir = f$parse(whoami,,,"DEVICE") + f$parse(whoami,,,"DIRECTORY")
$ WRITE SYS$OUTPUT "tag1"
$   set default 'procdir'
$ WRITE SYS$OUTPUT "tag2"

 The error is:

Wx01> @build_libxml.com
tag1
%RMS-F-DIR, error in directory name

 After it the system lost an ability to resolve correctlu current path:

dir
%DIRECT-E-OPENIN, error opening $1$DGA123:[ALEXANDER.VAX_ESF.LIBXML2-2_9_1.V
MS]*.*;* as input
-RMS-E-DNF, directory not found
-SYSTEM-W-NOSUCHFILE, no such file

This is the error in sources from official libxml site.

I've found more specialized port of sources.

Now:

  1. I'll try to run script from Maurizio De Tommaso_.
  2. Build port of sources.

Results of experiment will be reported. May be it will be usefull for somebody else.

PS. Thanks for help and your time.

Volker Halle
Honored Contributor

Re: libxml building

Alexander,

 

instead of WRITE SYS$OUTPUT "tag1", insert the following:

 

...

$   whoami = f$parse(f$environment("PROCEDURE"),,,,"NO_CONCEAL")
$   procdir = f$parse(whoami,,,"DEVICE") + f$parse(whoami,,,"DIRECTORY")
$ WRITE SYS$OUTPUT whoami

$ WRITE SYS$OUTPUT procdir
$   set default 'procdir'

...

 

Volker.

AlexanderM
Advisor

Re: libxml building

I've run script from Maurizio De Tommaso_.
Script:

Spoiler
$!  test.com
$!
$   whoami  = f$parse(f$environment("PROCEDURE"),,,,"NO_CONCEAL")
$   write sys$output " "
$   write sys$output "whoami symbol = ''whoami'"
$   write sys$output " "
$   procdir = f$parse(whoami,,,"DEVICE") + f$parse(whoami,,,"DIRECTORY")
$   write sys$output " "
$   write sys$output "procdir symbol = ''procdir'"
$   write sys$output " "
$   set default 'procdir'
$!
$   Exit

 

 

Result:

WX01> @test.com

whoami symbol = $1$DGA123:[TST$USERS.][ALEXANDER.VAX.LIBXML2-2_9_1]TEST.
COM;1


procdir symbol = $1$DGA123:[TST$USERS.][ALEXANDER.VAX.LIBXML2-2_9_1]

%RMS-F-DIR, error in directory name

 The same error occured.

AlexanderM
Advisor

Re: libxml building

Volker,

I've implemented your suggestion.
Result is the next:

WX01> @build_libxml.com
$1$DGA123:[TST$USERS.][ALEXANDER.VAX_ESF.LIBXML2-2_9_1.VMS]BUILD_LIBXML.COM;

$1$DGA123:[TST$USERS.][ALEXANDER.VAX_ESF.LIBXML2-2_9_1.VMS]
%RMS-F-DIR, error in directory name

 

It seems that the result is the same.