相关由于 Ubuntu 20.04 上的 Qt 不兼容,RStudio、VLC 和其他应用程序损坏
我正在尝试使用辅助功能选项构建 RStudio,这需要常规构建:
git clone [email protected]:rstudio/rstudio.git
cd rstudio
mkdir build && cd build
sudo ln -sf /usr/lib/x86_64-linux-gnu/qt5/plugins/platforms/ /usr/local/bin/
cmake .. -DRSTUDIO_TARGET=Desktop -DRSTUDIO_PACKAGE_BUILD=1 -DQT_QMAKE_EXECUTABLE=/usr/bin/qmake
由于找不到 libicu,make install 失败
[ 2%] Built target rstudio-shared-core
[ 4%] Built target rstudio-core-hunspell
[ 25%] Built target rstudio-core
[ 26%] Built target rstudio-session-workers
[ 26%] Built target rstudio-core-synctex
[ 27%] Built target rstudio-monitor
[ 33%] Built target rstudio-r
[ 75%] Built target rsession
[ 75%] Built target gwt_build
[ 76%] Built target rstudio-shared-core-tests
[ 82%] Built target rstudio-core-tests
[ 82%] Built target diagnostics
make[2]: *** No rule to make target '/usr/lib/lib/libicui18n.so', needed by 'src/cpp/desktop/rstudio'. Stop.
make[1]: *** [CMakeFiles/Makefile2:728: src/cpp/desktop/CMakeFiles/rstudio.dir/all] Error 2
make: *** [Makefile:152: all] Error 2
/usr/lib/lib/
我发现指向一个不存在的目录很奇怪。
答案1
我自己的解决方案,知道安装了 libicu-dev
sudo mkdir /usr/lib/lib
sudo ln -s /usr/lib/x86_64-linux-gnu/libicudata.so /usr/lib/lib/libicudata.so
sudo ln -s /usr/lib/x86_64-linux-gnu/libicuuc.so /usr/lib/lib/libicuuc.so
sudo ln -s /usr/lib/x86_64-linux-gnu/libicui18n.so /usr/lib/lib/libicui18n.so
sudo make install
结果
[ 2%] Built target rstudio-shared-core
[ 4%] Built target rstudio-core-hunspell
[ 25%] Built target rstudio-core
[ 26%] Built target rstudio-session-workers
[ 26%] Built target rstudio-core-synctex
[ 27%] Built target rstudio-monitor
[ 33%] Built target rstudio-r
[ 75%] Built target rsession
[ 75%] Built target gwt_build
[ 76%] Built target rstudio-shared-core-tests
[ 82%] Built target rstudio-core-tests
[ 82%] Built target diagnostics
[100%] Built target rstudio
[100%] Built target rpostback