代码拉取完成,页面将自动刷新
KD Chart 2.5.0 supports Qt version 4.x.
KD Chart 2.5.1 and later supports both Qt 4 and Qt 5.
If you are using sources from github (via a git clone or a generated zip file), jump
to section 1-bis). Commercial users, start at section 1).
1) From the top directory of your KD Chart installation
run the "configure" scripts.
On Windows use depending on the kind of build one of the following;
configure.bat -shared -debug
configure.bat -shared -release
On Unix or Mac use depending on the kind of build one of the following;
./configure.sh -shared -debug
./configure.sh -shared -release
To define the install-location use for example;
configure.bat -shared -debug -prefix c:/kdchart
./configure.sh -shared -debug -prefix /opt/kdchart
NOTE: Don't use relative paths for the prefix, they will not work.
1-bis) If you are building KD Chart from a github clone rather than a release tarball,
the configure.bat/configure.sh script doesn't exist (it's generated at release time),
you need to do this instead:
First, a working Python (version2) is required and must be found in your
execute path. Either a 32-bit or 64-bit version of Python is fine, but run
python --version to make sure it is found and is python2 before continuing.
Run autogen.py to create the configure tool:
python2 autogen.py [options]
c:\python27\python autogen.py [options]
Pass the same options to autogen.py as you would for configure.sh/configure.bat
as shown above in step 1).
After running autogen.py, a configure.sh/configure.bat script will exist and
you can use that to re-configure later, as needed. Then you can continue on
to the platform-specific setup instructions in step 2, 3 or 4.
2) Unix
set your LD_LIBRARY_PATH to point to your KD Chart installation lib directory.
If you do not have LD_LIBRARY_PATH set already then use this line:
LD_LIBRARY_PATH=/path/to/kdchart/lib:$LD_LIBRARY_PATH
export LD_LIBRARY_PATH
The above has to be added into your .bashrc or similar to remain. It may also of course
be run from a shell just before building KD Chart, but in this case your settings will
only be available for this shell.
If you want to install the libraries under the "lib64" folder then
set the QMAKE_ARGS environment variable to "LIB_SUFFIX=64" like so:
QMAKE_ARGS="LIB_SUFFIX=64"
export QMAKE_ARGS
3) MacOS
Proceed as described above, but using DYLD_LIBRARY_PATH instead
of LD_LIBRARY_PATH
4) Windows
Add the path to the KD Chart dll (kdchart\bin) into your PATH environment variable (for running executables)
and the path to the KD Chart lib (kdchart\lib) into your LIB environment variable (for development).
Or run:
set PATH=\path\to\kdchart\bin;%PATH%
set LIB=\path\to\kdchart\lib;%LIB%
5) Compile everything by typing:
make # Unix, Mac
nmake # Windows
On Windows you can also use the Qt integration into Visual Studio:
open the toplevel kdchart.pro with "Qt / Open Solution from .pro file".
You still need to adjust the PATH environment variable in order to run the examples.
6) (optionally:) Install KD Chart:
From your top-level KD Chart directory just type
make install # Unix, Mac
nmake install # Windows
This will copy the necessary files into the sub-directories of
your installation path: eg. /usr/local/KDAB/KDChart-VERSION/
UNIX,Mac Note): Admin rights may be required for installing to /usr/local.
Run "sudo make install", to install with admin rights.
7) Have a look at the example applications to get you started with the KD Chart 2.x API.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。