Building C++ XML projects (Linux)

Building C++ XML projects (Linux)

First, generate your library from your XML Schema (Note: this must be done on a Windows platform as the Wizard is for Windows only), this create a file called Makefile_Linux which will compile and link your library. Next, copy the project file and all .cpp and .h files over to your Linux system. You can then create a new project on Linux for your application.

Altering the Makefile
You may need to alter the Makefile_Linux file to set up paths appropriate to your system. The default values are as follows:

# compiler include dirs

# external libs path

These paths must point to the redistributable files provided as part of the Liquid XML Data Binding Wizard install.

Running make
The makefile has been tested against GNU g++ on the following platforms:

- Linux x86 32 bit (g++ 3.2 under RedHat 8.0, g++ 3.2.2 under Mandrake 9.1, g++ 3.4.1 under Mandrake 10.1, g++ 4.2.4 under Ubuntu 8.0 and g++ 4.3.3 under Ubuntu 9.0)

- Linux x86 64 bit (g++ 4.0.0 under Fedora 4 and g++ 4.4.4 under Fedora Core 13)

Note: g++ 3.3.x and 3.4.0 do not work due to a compiler issue, but 3.4.1 works fine!!

Providing you have this available on your path, you can simply type 'make -fMakefile_Linux' fom the command line in the appropriate directory and both debug and release builds of you library will be built.

Other targets included in the Makefile are:
release - release build only
debug - debug build only
clean - deletes any object and library files previously created
release_clean - deletes release files only
debug_clean - deletes debug files only

Linking to your Library
In order to link against your library you must include both the path to the Liquid Technologies runtime header and library files and the generated header and library files in your applications makefile. In order to run your application you will also require all libraries to be on the library path. You can do this by adding the directories to the LD_LIBRARY_PATH.