Difference between revisions of "Installing the Chart Handling Libraries"
From AgileApps Support Wiki
Wikidevuser (talk | contribs) |
Wikidevuser (talk | contribs) |
||
(One intermediate revision by the same user not shown) | |||
Line 4: | Line 4: | ||
==== Install php-cli ==== | ==== Install php-cli ==== | ||
# Install <tt>php-cli</tt> from PHP version 8.2.21, or later. | # Install <tt>php-cli</tt> from PHP version 8.2.21, or later. | ||
====Install the FCImg Library==== | ====Install the FCImg Library==== | ||
Line 18: | Line 13: | ||
#:<tt>chown {platform_admin_user} fcimg/</tt> | #:<tt>chown {platform_admin_user} fcimg/</tt> | ||
#:''Learn more:'' [[Running the Platform as a Non-Root User]] | #:''Learn more:'' [[Running the Platform as a Non-Root User]] | ||
#: | |||
# From the installation folder, copy the <tt>template.txt</tt> file to <tt>fcimg/</tt> | |||
#:<tt>cp ${platform_installation_dir}/template.txt fcimg/</tt> | |||
#: | |||
# Download the appropriate library for your OS: | |||
#* Linux (32 Bit) {{DOCHOST}}/files/fcimg-0.1.3-linux32bit.tar.gz | |||
#* Linux (64 Bit) {{DOCHOST}}/files/fcimg-0.1.3-linux64bit.tar.gz | |||
#: | #: | ||
# Extract the FCImg library into <tt>${TOMCAT_HOME}/fcimg/</tt> <br>(The directory is created by the installation process. It contains a <tt>template.txt</tt> file.) | # Extract the FCImg library into <tt>${TOMCAT_HOME}/fcimg/</tt> <br>(The directory is created by the installation process. It contains a <tt>template.txt</tt> file.) | ||
Line 34: | Line 36: | ||
#:<tt>$args = $args." --crop-h ".($height - 1); </tt> | #:<tt>$args = $args." --crop-h ".($height - 1); </tt> | ||
#:<tt>$args = $args." --encoding utf-8"; </tt> | #:<tt>$args = $args." --encoding utf-8"; </tt> | ||
#: | |||
# Make the files executable: | |||
#:<tt>cd ${TOMCAT_HOME}</tt> | |||
#:<tt>chmod +x fcimg/bin/*</tt> | |||
====Install MS True Type Fonts==== | ====Install MS True Type Fonts==== |
Latest revision as of 08:57, 23 October 2024
These libraries create an image of charts generated by reports, so the charts can be viewed when the report is sent in an email.
Install php-cli
- Install php-cli from PHP version 8.2.21, or later.
Install the FCImg Library
- Create the fcimg/ directory:
- cd ${TOMCAT_HOME}
- mkdir fcimg/
- Change the directory owner to the user who will be starting tomcat:
- chown {platform_admin_user} fcimg/
- Learn more: Running the Platform as a Non-Root User
- From the installation folder, copy the template.txt file to fcimg/
- cp ${platform_installation_dir}/template.txt fcimg/
- Download the appropriate library for your OS:
- Linux (32 Bit) https://agileappscloud.info/aawiki-src/download/files/fcimg-0.1.3-linux32bit.tar.gz
- Linux (64 Bit) https://agileappscloud.info/aawiki-src/download/files/fcimg-0.1.3-linux64bit.tar.gz
- Extract the FCImg library into ${TOMCAT_HOME}/fcimg/
(The directory is created by the installation process. It contains a template.txt file.) - For 10.5 versions and above, make the following changes in fcimg.php file in the fcimg folder .
- add $args = $args." --encoding utf-8"; right after the below mentioned lines.
- // configure the arguments
- $args = "--format $fileType";
- $args = $args." --crop-w ".($width - 1);
- $args = $args." --crop-h ".($height - 1);
- resultant text will look like
- // configure the arguments
- $args = "--format $fileType";
- $args = $args." --crop-w ".($width - 1);
- $args = $args." --crop-h ".($height - 1);
- $args = $args." --encoding utf-8";
- Make the files executable:
- cd ${TOMCAT_HOME}
- chmod +x fcimg/bin/*
Install MS True Type Fonts
On Windows, True Type fonts are pre-installed. For RedHat Linux:
- Make sure the following rpm packages are installed. (Any version should do.)
- rpm-build
- wget {a package that provides the ttmkfdir utility}
- For example:
- For Fedora Core and Red Hat Enterprise Linux 4, ttmkfdir
- For old redhat releases, XFree86-font-utils
- For mandrake-8.2, freetype-tools
- For example:
- Install the cabextract utility.
- For users of Fedora Core it is available from extras.
- Others may want to compile it themselves from source, or download the source rpm from fedora extras and rebuild.
- If you don't have an rpm-based distribution, compile the tool to extract the .ttf files from the .exe files, cabextract from the source files at http://www.cabextract.org.uk/
- Download the latest msttcorefonts spec file
- If you haven't done so already, set up an rpm build environment in your home directory:
- a. Edit $HOME/.rpmmacros
- b. Add the line %_topdir %(echo $HOME)/rpmbuild
- c. Create the directories $HOME/rpmbuild/BUILD and $HOME/rpmbuild/RPMS/noarch
- Build the binary rpm:
- rpmbuild -bb msttcorefonts-2.0-1.spec
- This command downloads the fonts from a Sourcforge mirror, and repackages them so that they can be easily installed.
- Install the newly built rpm as the root user:
- rpm -ivh $HOME/rpmbuild/RPMS/noarch/msttcorefonts-2.0-1.noarch.rpm
- Take additional steps to finish the installation, as needed:
- You might need to reload the X font server. Normally this is done as a part of the installation process (by chkfontpath). However in some situations it seems like you need to reload or restart the font server manually. (On Mandrake 9.0, the last argument needs to be restart rather than reload.)
- /sbin/service xfs reload
- A bug in RedHat 8.0 makes the X server lose the connection to the font server if the font server is restarted instead of reloaded. producing assorted strange behaviors (changed fonts in newly opened applications, applications hanging). Logging out and logging in again solves the problems, or just use 'reload' instead of 'restart'.}}
- Verify that the installation succeeded:
- xlsfonts | grep ^-microsoft
- The list includes many microsoft and monotype font names.
- Restart all programs that need to be aware of the new fonts.
Learn more: An easy way to install Microsoft's True Type core fonts on Linux