How to install tclxml package

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf How to install tclxml package

  • Creator
    Topic
  • #54087
    Peter Heggie
    Participant

      How can I install tclxml 3.2 without messing up the current Cloverleaf tcl configuration?

      I’ve read a lot about pkgIndex and commands that read it and the Cloverleaf commands that create their own indexes, but I still don’t understand how to install tclxml.

      I understand “package ifneeded dom 3.0” but I don’t understand “package ifneeded dom::tcl 3.0” . What is the significance of the ‘::tcl’ ?

      I thought most packages come with a pkgIndex.tcl but this one does not. I’ve copied the three directories that I thought were important from the entire download – tcldom-tcl, tclxml-tcl and tclxslt – into a single directory under $HCISITE/tclprocs. Running mkpkgindex results in several error messages:

      Quote:

      warning: error while sourcing xpath.tcl: can’t read “::xml::QName”: no such variable

      . It creates a pkgIndex.tcl file but when I run a tcl that has a “package require xpath” I get an error  

      Quote:

      can’t find package xpath

      . If I  remove the package require xpath, it does not get much further:

      Quote:

      can’t find package xml 3.0                                              

         while executing                                                      

      “package require xml 3.0”                                                

         (file “/hci/cis6.0/integrator/chonltst/tclprocs/lib/dom.tcl” line 18)

         invoked from within                                                  

      “source /hci/cis6.0/integrator/chonltst/tclprocs/lib/dom.tcl”            

         (“package ifneeded dom::tcl 3.0” script)                            

         invoked from within                                                  

      “package require dom::tcl”                                              

         (file “/home/hci/scripts/xml_package.tcl” line 7)                    

      This seems strange because the pkgIndex.tcl seems to have it listed:

      Quote:


      package ifneeded dom::tcl 3.0

        ]

        package ifneeded dommap 1.0

          ]

          package ifneeded sgml 1.9

            ]

            package ifneeded xml::dep 1.0

              ]

              package ifneeded xml::tcl 3.1

                ]

                package ifneeded xmlswitch 3.2

                  ]

                  package ifneeded xslt::cache 3.2

                    ]

                    package ifneeded xslt::resources 1.3

                      ]

                      package ifneeded xslt::utilities 1.2

                        ]


                        I need to be able to use xpath notation to find certain child xml tags, among repeated child tags, that have certain attribute values.

                        Is there another way to get xpath or tcldom installed?

                        Thanks,

                        Pete

                        Peter Heggie
                        PeterHeggie@crouse.org

                      Viewing 2 reply threads
                      • Author
                        Replies
                        • #80109
                          Robert Milfajt
                          Participant

                            I tried to install TCL xml a while back and I don’t have all the details, but you will start going down a rabbit hole finding there are several other required packages you will need to install, and some of these will require compiling (at least on AIX).  Good luck, I abandoned the pursuit and solved it by working with a programmer from our web team and an intermediate application on that server.

                            Robert Milfajt
                            Northwestern Medicine
                            Chicago, IL

                          • #80110
                            Elisha Gould
                            Participant

                              I had a quick play with tclxml 3.2 with cloverleaf 6.0

                              To build from src and install:

                              Code:

                              ./configure –build=i686-pc-linux-gnu “CFLAGS=-m32” “CXXFLAGS=-m32” “LDFLAGS=-L$HCIROOT/tcl/lib -L/usr/lib -m32” –with-tcl=$HCIROOT/tcl/lib –with-tclinclude=$HCIROOT/tcl/include

                              make all
                              make install

                              The install copies the library and tcl code to $HCIROOT/tcl/lib/Tclxml3.2 and some includes to $HCIROOT/tcl/include/tclxml

                              It does not overwrite any files in the lib directory.

                              You could also manually copy the tcl/library files from tclxml-3.2, tclxml-3.2/tclxslt, tclxml-3.2/tclxml-tcl, and tclxml-3.2/tcldom-tcl to $HCIROOT/tcl/lib/Tclxml3.2. Look at the Makefile for the exact files that are copied.

                              There are memory leaks in tclxml 3.2, so these would need to be fixed before usage. I’ve had a quick look, but havn’t found where the fix for the leak needs to go yet.

                              There are also a few panics that can occur, so best to fix those first too.

                            • #80111
                              Peter Heggie
                              Participant

                                Thank you for the information – it is disappointing that there are memory leaks. Debugging that kind of problem is beyond my current knowledge, and it is good to know that the problem exists. Maybe it would be easier to use a Java UPOC? I tried writing a very crude xpath parser and was quickly overwhelmed.

                                Peter

                                Peter Heggie
                                PeterHeggie@crouse.org

                            Viewing 2 reply threads
                            • The forum ‘Cloverleaf’ is closed to new topics and replies.