Linux Installation
This chapter shows you how to install and setup DocxFactory on Linux.
Go to www.docxfactory.com and download the Linux installation package.
For the Linux 32bit version download DocxFactoryLinux32.tar.gz.
For the Linux 64bit version download DocxFactoryLinux64.tar.gz.
Before starting, it is recommended that you login as root so you have all the necessary permissions to perform the installation.
Enter the commands below in the command line.
$ su - |
Extract the DocxFactory/ directory into the /opt directory.
Enter the commands below in the command line.
# cd /opt # tar -zxvf DocxFactoryLinux32.tar.gz |
Note: If there is an older version installed then delete the DocxFactory directory first (do not overwrite it).
Add the DocxFactory/lib/ directory to the list of library directories to search when a program is run.
Either permanently using ldconfig:
# echo /opt/DocxFactory/lib/ > /etc/ld.so.conf.d/DocxFactory.conf # chmod 666 /etc/ld.so.conf.d/DocxFactory.conf # ldconfig |
Or temporarily using the LD_LIBRARY_PATH environment variable before the program is run:
# export LD_LIBRARY_PATH=/opt/DocxFactory/lib:$LD_LIBRARY_PATH |
Note: You will need to restart all processes that use the DocxFactory.so (or simply restart the Computer) for the changes to take effect.
To compile C programs using DocxFactory with the GNU C Compiler:
Add the DocxFactory/include/ directory to the list of include directories.
Link to the libDocxFactory.so library.
See example below.
# gcc -c <program.cpp> -I/opt/DocxFactory/include # gcc -o <executable> <program.o> \ -L/opt/DocxFactory/lib –l:libDocxFactory.so |
Note: The backslash “\” at the end of line causes the command to continue in the next line. The command is broken into several lines to fit in the page. You can write the command in a single line without backslashes.