Как разработать проект C++ на удаленном компьютере в Eclipse?

Как насчет удаления всего остального?

data <- c("Demand = 001 979", "Demand = -08 976 (154)", "Demand = -01 975 (359)")
data <- gsub("Demand = ", "", x = data)
data <- trimws(gsub("\\(.*\\)", "", x = data))

out <- list()

out[[1]] <- sapply(data, "[", 1)
out[[2]] <- sapply(data, "[", 2)
out

[[1]]
[1] "001" "-08" "-01"

[[2]]
[1] "979" "976" "975"
27
задан r0u1i 13 May 2009 в 08:20
поделиться

5 ответов

You can create a project on a remote machine using RSE. To do so you must have the RSE server component installed on the remote machine. Create a connection to the machine using the RSE Remote Systems view. Create a new C/C++ project and on the first page of the wizard uncheck the checkbox that says "use default location". This enables a dropdown of file system providers, choose RSE. Then when you click Browse you will get a dialog that lets you browse the remote system for the folder where you want your project to live.

There are a few issues with this approach. First of all when the CDT indexer wants to build the index it needs to parse all the files in your project, which means downloading all the files to your local machine. This can be slow if you have a large project or a slow connection.

Another issue is that when you restart eclipse the remote projects will be closed. This is because you don't have a connection to the remote machine yet so eclipse can't read the .project file. You will have to reopen your remote projects every time you start eclipse.

There is currently a project in the works called RDT (Remote Development Tools) which adds remote indexing capabilities to CDT. That means the indexer will live on the remote machine with your code, so the files don't have to be downloaded for the indexer. Its still in "alpha" status, but if you are adventurous and want to try it out go here.

8
ответ дан 28 November 2019 в 05:38
поделиться

Пробовали ли вы инструменты удаленного рабочего стола, такие как, например, nx , для локального запуска eclipse на машине, которая также содержит исходный код?

Это могло бы быть более простым решением. Кроме того, у вас есть такая же среда с любого ПК, на котором работает этот инструмент.

3
ответ дан 28 November 2019 в 05:38
поделиться

Have you tried running Eclipse from the Linux machine with X11 forwarding ? You should have Eclipse installed on the Linux machine first.

Haven't tried it myself.

0
ответ дан 28 November 2019 в 05:38
поделиться

Like Liran Orevi said you can use x windows.

  1. Install the cygwin x server on your windows system.
  2. Enable remote connections to this X server using "xhost +" or similar (xhost + is not considered secure so don't do it on a public network but its ok for most cases)
  3. ssh on to the linux box
  4. set the DISPLAY environment variable eg "export DISPLAY=":0"
  5. run eclipse from the command line Eclipse should now appear on xserver on the windows system.

ssh can automate the forwarding, removing the need for xhost + and the DISPLAY env.

0
ответ дан 28 November 2019 в 05:38
поделиться

I was in a similar situation, developing in a windows workstation, compiling in a linux server. This is what I ended doing:

  1. Setup a passwordless login to the compiler server with putty, for example you can follow this tutorial.
  2. Create a login session with putty, make sure that in Connections/SSH/Auth is pointing to your private key.
  3. Modify eclipse make command to plink.exe -load "saved_session" make -C /remote/path/project (This setting is in Project/Properties/C++Build/Builder Settings/Build command). You can automate this with a batch/shell file if you have to pass more parameters and/or your setup is more complex.

If you have stored a passphrase with your private key then you can use pageant.exe to load your key only once, so you dont have to type your passphrase every time.

21
ответ дан 28 November 2019 в 05:38
поделиться
Другие вопросы по тегам:

Похожие вопросы: