引用:https://blog.csdn.net/weixin_40420213/article/details/78687540
1.安装gcc,gcc-c++ ,m4
2.安装gmp-4.3.2
../configure --prefix=/usr/local/gmp-4.3.2
make
make install
3.安装mpfr-2.4.2
https://www.mpfr.org/mpfr-2.4.2/
../configure --prefix=/usr/local/mpfr-2.4.2 --with-gmp=/usr/local/gmp-4.3.2
4.安装mpc-0.8.1.tar.gz
https://sourceforge.net/projects/tdm-gcc/files/Sources/Vanilla%20Sources/_Deprecated/mpc/mpc-0.8.1/
../configure --prefix=/usr/local/mpc-0.8.1 --with-gmp=/usr/local/gmp-4.3.2 --with-mpfr=/usr/local/mpfr-2.4.2
5.环境变量
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/gmp-4.3.2/lib:/usr/local/mpc-0.8.1/lib:/usr/local/mpfr-2.4.2/lib
6.安装gcc
../configure --prefix=/usr/local/gcc-5.4.0 --enable-threads=posix --disable-checking --disable-multilib --enable-languages=c,c++ --with-gmp=/usr/local/gmp-4.3.2 --with-mpfr=/usr/local/mpfr-2.4.2 --with-mpc=/usr/local/mpc-0.8.1
报错:
解决:yum installgcc-c++
mkdir /usr/gcc447backup/
mv /usr/bin/{gcc,g++} /usr/gcc447backup
ln -s /usr/local/gcc-5.4.0/bin/gcc /usr/bin/gcc
ln -s /usr/local/gcc-5.4.0/bin/g++ /usr/bin/g++
ln -s /usr/local/gcc-5.4.0/bin/c++ /usr/bin/c++
gcc -v
7.安装boost
gstreamer-python-devel.x86_64
./bootstrap --prefix=/usr/local
./b2 install
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
export C_INCLUDE_PATH=/usr/local/boost/include/boost:$C_INCLUDE_PATH
export CPLUS_INCLUDE_PATH=/usr/local/boost/include/boost:$CPLUS_INCLUDE_PATH
export LD_LIBRARY_PATH=/usr/local/boost/lib:$LD_LIBRARY_PATH
export LIBRARY_PATH=/usr/local/boost/lib:$LIBRARY_PATH
8.安装cmake
./configure
报错 缺少20,21
解决:
yum provides libstdc++.so.6
yum install libstdc++*
find libstdc++.so*
1、cp /usr/local/lib64/libstdc++.so.6.0.25 /usr/lib64
2、 mv /usr/lib64/libstdc++.so.6 /usr/lib64/libstdc++.so.6_old
3、ln /usr/lib64/libstdc++.so.6.0.25 /usr/lib64/libstdc++.so.6
再运行strings /usr/lib64/libstdc++.so.6 | grep GLIBCXX
make make install
9.安装openssl1.0.1g
wget https://www.openssl.org/source/openssl-1.0.1g.tar.gz
./config --prefix=/usr/local/
make && make install
./configure shared –prefix=/path/to/install配置编译安装动态库
make && make install
10.安装cpprest
https://github.com/Microsoft/cpprestsdk
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr -DBOOST_ROOT=/opt/boost/ -DWERROR=OFF -DBUILD_TESTS=OFF -DBUILD_SAMPLES=OFF
报错如图
输入:git submodule update --init
报错 -DWERROR
make
sudo cp Binaries/libcpprest.so /usr/lib
sudo ldconfig
sudo mkdir -p /usr/include/casablanca
sudo cp -r ../Release/include/* /usr/include/casablanca
11.安装EHS
https://github.com/cloudbase/EHS.git
mkdir -p build && cd build && cmake -DBOOST_ROOT=/opt/boost/ -DCMAKE_INSTALL_PREFIX=/usr ..
make
make install
aclocal -I m4
autoconf configure.ac
autoreconf -vif
./configure
报错
yum install -y libtool libsysfs
报错
yum install boost-devel
./configure 里面boost路径重新选择,选择安装路径
报错+解决
./configure --with-ssl --with-boost=/opt/boost/ --prefix=/usr/
12.安装Freerdp
https://github.com/FreeRDP/FreeRDP.git
教程https://blog.csdn.net/jackalfly/article/details/8111273
yum install gcc cmake openssl-devel libX11-devel libXext-devel libXinerama-devel libXcursor-devel libXdamage-devel libXv-deve libxkbfile-devel cups-devel alsa-lib-devel pcsc-lite-devel
git clone https://github.com/FreeRDP/FreeRDP.git
mkdir -p build && cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr ..
make
make install
sudo touch /etc/ld.so.conf.d/freerdp.conf
echo '/usr/lib/x86_64-linux-gnu' > ./freerdp.conf
sudo mv ./freerdp.conf /etc/ld.soc.conf.d/
sudo ldconfig
报错
sudo yum install libXv-devel libXv-devel.i686
13.安装依赖
yum install -y gcc-c++ svn subversion-svn2cl openssl-devel \
libpng-devel elfutils-devel glib2-devel
14.安装java
http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
把jdk-8u171-linux-x64.tar.gz下载到本地
cd /usr/local
mkdir java
cd java/
tar -xzvf jdk-8u171-linux-x64.tar.gz
mv jdk1.8.0_171 jdk1.8
vim /etc/profile
配置系统环境变量
而不是用户环境变量
添加
JAVA_HOME=/usr/local/java/jdk1.8
JRE_HOME=/usr/local/java/jdk1.8/jre
PATH=$PATH:$JAVA_HOME/bin:$JRE_HOME/bin
CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:$JRE_HOME/lib
export JAVA_HOME=/usr/local/java/jdk1.8
export JRE_HOME= /usr/local/java/jdk1.8/jre
source /etc/profile
使配置生效
java -version
查看java版本
15.安装freerdp-webconnect
https://github.com/FreeRDP/FreeRDP-WebConnect
mkdir build
cmake .. -DBOOST_ROOT=/opt/boost/
报错---安装java去,以下问题解决
报错
修改
cmake .. -DBOOST_ROOT=/opt/boost/ -DFREERDP_ROOT=/usr/local/repos/FreeRDP -DWINPR_ROOT=/usr/local/repos/FreeRDP/winpr
cmake .. -DBOOST_DIR=/opt/boost/ -DFREERDP_INCLUDE_DIR=/usr/local/repos/FreeRDP -DWINPR_INCLUDE_DIR=/usr/local/repos/FreeRDP/winpr -DEHS_INCLUDE_DIR=/root/FreeRDP-WebConnect/prereqs/EHS
CMAKE_INSTALL_DATADIR=/usr/lib64/cmake
EHS_INCLUDE_DIR=/usr/include/ehs
HAVE_LIBDWFL_H:FILEPATH=/usr/include/elfutils/libdwfl.h
LIB_WINPR:FILEPATH=/usr/local/lib64/libfreerdp2.so
执行build下
./wsgate