[xsd-users] Code Generation with AutoTools
Steve Sloan
steve at finagle.org
Fri Feb 20 12:20:09 EST 2009
I'm starting a project using XSD, but am having some trouble generating
the C++ (tree) code with AutoTools. My simplistic approach was just to
add the generated filenames (e.g. Schema.hxx, Schema.cxx) to the
"app_SOURCES" line in Makefile.am, and add a rule to run XSD to create
them from the .xsd file.
I have two issues with this:
1. It tries to compile the generated files, fails because they don't
exist, then generates them. On a fresh source tree, I have to run make
twice to get a successful build. I suspect this is a side effect of
libtool or automake.
2. The generated files must reside in $srcdir, instead of $builddir.
This is only an issue when building under KDevelop, but it clutters up
the source tree.
Any advice would be greatly appreciated ...
-- Steve
More information about the xsd-users
mailing list