Berin/David,
I tried the script and all seems to build and run. All I noticed was
that 'Tests' need to be updated as well.
Has there been any further progress regarding this proposed change? Has
any timeframe been established to commit to Xalan? What are the
outstanding issues?
-Matt.
Matthew Hoyt
IBM Toronto Lab
email: [EMAIL PROTECTED]
Berin Lautenbach
<[EMAIL PROTECTED] To: [EMAIL PROTECTED]
m.au> cc:
Subject: Re: "Sane includes" for Xalan
06/14/2003 05:57
AM
Please respond to
xalan-dev
David/Matthew,
Attached is a bash script and a sed script which will convert the source
and VC++ project files to the new directory structure. (Not the
makefile though - it's simpler just to edit.)
Would appreciate if you could both cast your eye over them and see if
there is anything I have missed. I have run this against current CVS
(as at time of sending) and then compiled up (and executed) the
TransformToXerces sample.
The TransformToXerces sample has been compiled under VC6++ and Linux (gcc).
Here is how I propose to transition over :
David - I will need you to nominate a point in time when you are happy
for me to run the script such that there will be no changes made to the
C code until I e-mail back that all is done. (I need the C part of the
CVS "frozen", otherwise we may lose things as I move the directories.)
Then I will :
1. update my local copy of xalan against CVS at that point in time.
2. run the script under Cygwin, compile the projects under the new
structure and run some quick tests under VC++.
3. upload the changes to cvs.apache.org. This will require
deleting all the old files from cvs and then importing the new src
structure.
4. update src on linux machine and modify the makefile to operate
correctly. (This is simply a matter of adding "xalanc" to the *_SRC
variables at the top of Makefile.in.)
5. compile the samples under Linux and validate they appear to work
correctly.
6. commit linux changes back to CVS.
7. E-mail to Xalan-dev "unfreezing" the CVS.
I'll then need someone to test the ICU compiles - I don't have an ICU
build setup here. (Really must set that up.)
Thoughts? Any suggested date/time?
Cheers,
Berin
Berin Lautenbach wrote:
> Matthew Hoyt wrote:
>
>>
>>
>>
>> I am proposing that Xalan follow Xerces, and many other projects, and
>> restructure to enable proper support for "sane includes". I am
looking
>> for approval to implement, test and contribute this change to Xalan.
>
>
> For all the reasons you discussed, I have been working on exactly this
> for the next release. To me it's the pre-cursor to re-doing the
> make/configure system. The problem is more one of logistics than work.
> (Although getting free time has been a big problem of late.)
>
> We also discussed taking a more makefile approach to the problem, and
> creating the xalanc directory during build time. This is what is done
> in the xml-security-c library, but it's a pain in the proverbial because
> of what it does to VC++.
>
> Cheers,
> Berin
>
>
#!/bin/bash
updatesrc () {
for i in $1; do
cp $i $i.bak
sed -f ../update-sed $i.bak > $i
rm $i.bak
echo $i updated
done
}
# Update main source directories
echo "Updating main source directory #includes"
updatesrc "c/src/*/*.[ch]pp"
updatesrc "c/src/*/*.[ch]"
# Creating xalanc and moving files in
# echo "Creating xalanc"
mkdir c/src/xalanc
# Ugly - lots of errors, but works.
mv c/src/* c/src/xalanc
# Update sample code
echo "Updating sample code #includes "
updatesrc "c/samples/*/*.[ch]pp"
updatesrc "c/samples/*/*.[ch]"
# Update Project files
echo "Updating VC6++ project files"
for i in c/Projects/Win32/VC6/*/*.dsp; do
cp $i $i.bak
sed
"s/SOURCE=..\\\\..\\\\..\\\\..\\\\src\\\\/SOURCE=..\\\\..\\\\..\\\\..\\\
\src\\\\xalanc\\\\/g" $i.bak > $i
rm $i.bak
echo $i updated
done
s/\(#include.*[<\"]\)\(XalanDOM\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(DOMSupport\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(Include\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(ICUBridge\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(PlatformSupport\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XalanSourceTree\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XMLSupport\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XPath\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XPathCAPI\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XSLT\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XalanExtensions\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XercesParserLiaison\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XalanEXSLT\/\)/\1xalanc\/\2/g
s/\(#include.*[<\"]\)\(XalanTransformer\/\)/\1xalanc\/\2/g