[Patch] - Makefile modification for zOS porting

Stéphane Michaut <[email protected]>
Newsgroups gmane.comp.gnome.lib.xml.general
Message-ID <VI1PR0102MB27176D4C8FE4499AC3841E37DFB30@VI1PR0102MB2717.eurprd01.prod.exchangelabs.com>
Here is the diff -u of Makefile.in with the changes I had to make in order to make it works on zOs. See Makefile-modif.txt for explanation.

I also need an extra option in configure for C compile, but I don't know how to modify Makefile.in or configure files to take it into account, so I change Makefile directly!

The original generated Makefile had

CFLAGS = -g

I need a 'compile-dll' option that generate this line

CFLAGS = -g -W c,exportall -W c,dll

Regards,

Stéphane

_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
[email protected]
https://mail.gnome.org/mailman/listinfo/xml
diff-Makefile.in (application/octet-stream, 7.8 KB) - not displayed
Makefile-modif.txt (text/plain, 1.7 KB)
- since testapi.c file is huge (over 52000 lines), it's compilation fails: I skipped the problem by removing all references to testapi in the Makefile.in, 
  but it would be neater if one can build without test files (I didn't find an option in configure...)

- since the name of files (or qualifier) in PDS are limited to 8 I had to rename xmlschemas.c and xmlschemastypes.c in (resp.) xmlsche.c xmlschet.c 
  (and I had to modify all occurences of these files accordingly in the rest of the Makefile !!!). 

- in order to copy objects to PDS, I had the cp command at line 860 of Makefile.in

libxml2.la: $(libxml2_la_OBJECTS) $(libxml2_la_DEPENDENCIES)
        $(AM_V_CCLD)$(libxml2_la_LINK) -rpath $(libdir) $(libxml2_la_OBJECTS) $(libxml2_la_LIBADD) $(LIBS)
        # Copy objects to PDS
        @list='$(libxml2_OBJECTS)' ; for p in $$list; do \
          cp -ACMv $$p "//'<PDS NAME>'"; \
        done

	with <PDS NAME> stands for the name of my PDS and
	
libxml2_OBJECTS = SAX.o entities.o encoding.o error.o \
	parserInternals.o parser.o tree.o hash.o list.o xmlIO.o \
	xmlmemory.o uri.o valid.o xlink.o HTMLparser.o \
	HTMLtree.o debugXML.o xpath.o xpointer.o xinclude.o \
	nanohttp.o nanoftp.o triostr.o trio.o catalog.o globals.o \
	threads.o c14n.o xmlstring.o buf.o xmlregexp.o \
	xmlsche.o xmlschet.o xmlunicode.o \
	xmlreader.o relaxng.o dict.o SAX2.o \
	xmlwriter.o legacy.o chvalid.o pattern.o xmlsave.o \
	xmlmodule.o schematron.o xzlib.o 

In order to handle the support of zOS without breaking the existing Makefile maybe a new option/flag zOs would copy xmlschemas.c and xmlschemastypes.c files and use specifics 
targets rather than existing ones with the longer names... A variable to handle the PDS name has to be provided also...
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.