2016-08-03 159 views
1

我已經跟隨在INSTALL 安裝STEP但是當我安裝包[R安裝包Rcplex

c:/Rtools/mingw_32/bin/gcc -I"C:/PROGRA~1/R/R-33~1.1/include" -DNDEBUG -I"C:/Program Files/IBM/ILOG/CPLEX_Studio_Community1263/cplex/include" -I"d:/Compiler/gcc-4.9.3/local330/include" -O3 -Wall -std=gnu99 -mtune=core2 -c Rcplex.c -o Rcplex.o 
c:/Rtools/mingw_32/bin/gcc -I"C:/PROGRA~1/R/R-33~1.1/include" -DNDEBUG -I"C:/Program Files/IBM/ILOG/CPLEX_Studio_Community1263/cplex/include" -I"d:/Compiler/gcc-4.9.3/local330/include" -O3 -Wall -std=gnu99 -mtune=core2 -c Rcplex_QCP.c -o Rcplex_QCP.o 
Rcplex_QCP.c: In function 'Rcplex_QCP': 
Rcplex_QCP.c:37:7: warning: unused variable 'trace' [-Wunused-variable] 
int trace = INTEGER(getListElement(control,"trace"))[0]; 
    ^
c:/Rtools/mingw_32/bin/gcc -I"C:/PROGRA~1/R/R-33~1.1/include" -DNDEBUG -I"C:/Program Files/IBM/ILOG/CPLEX_Studio_Community1263/cplex/include" -I"d:/Compiler/gcc-4.9.3/local330/include" -O3 -Wall -std=gnu99 -mtune=core2 -c Rcplex_params.c -o Rcplex_params.o 
c:/Rtools/mingw_32/bin/gcc -I"C:/PROGRA~1/R/R-33~1.1/include" -DNDEBUG -I"C:/Program Files/IBM/ILOG/CPLEX_Studio_Community1263/cplex/include" -I"d:/Compiler/gcc-4.9.3/local330/include" -O3 -Wall -std=gnu99 -mtune=core2 -c Rcplex_utils.c -o Rcplex_utils.o 
C:/Rtools/mingw_32/bin/../lib/gcc/i686-w64-mingw32/4.9.3/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -lcplex1263 
collect2.exe: error: ld returned 1 exit status 
no DLL was created 
ERROR: compilation failed for package 'Rcplex' 

回答

0

當你去包文檔的一些錯誤發生:https://cran.r-project.org/web/packages/Rcplex/index.html ...你沒有提到的滿意系統要求:

SystemRequirements: IBM ILOG CPLEX libraries and headers 
+0

我有軟件CPLEX。但仍然無法安裝 那麼該軟件包不能用於Windows? –

+0

您可以在不使用R的情況下運行CPLEX代碼嗎? http://www.ibm.com/support/knowledgecenter/SSSA5P_12.6.3/ilog.odms.studio.help/Optimization_Studio/topics/COS_relnotes_intro.html –

+0

是的,我可以!你會知道什麼是錯的嗎? –

0

gcc用途,ld,找不到CPLEX共享庫的鏈接。根據INSTALL文檔,您需要驗證CPLEX_LIB_PATH被定義爲指向CPLEX dll所在的路徑。從你的輸出中,我願意冒險

set CPLEX_LIB_PATH="C:/Program Files/IBM/ILOG/CPLEX_Studio_Community1263/cplex/lib" 

是你需要的。