Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2008-05

Mac OS X : Using TProcess to launch Unix command to Copy a Directory

4 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Dominique Louis

Hi all,
I'm passing the following command to a TProcess instance...

cp -R /SomePath/MyGame.app /SomePath/MyNewGame.app

via it's command line property, but it did not work.

I then tried fpsystem, passing it the same string and it also fails with a 16384 error, which I've spent the last half hour searching for on Google, but it does not appear anywhere.

So any help would be greatly appreciated.

Dominique.

Reply by email

Vincent Snijders
to Dominique Louis
Dominique Louis wrote 7 lines
Hi all, I'm passing the following command to a TProcess instance... cp -R /SomePath/MyGame.app /SomePath/MyNewGame.app via it's command line property, but it did not work.

Maybe you should give a full path for cp. So
/bin/cp -R /SomePath/MyGame.app /SomePath/MyNewGame.app

Vincent

Reply by email

Mattias Gaertner
to Dominique Louis: I'm passing the following command to a TProcess instance... cp -R /SomePath/MyGame.app…
Show quoted text 6 lines
Hi all, I'm passing the following command to a TProcess instance... cp -R /SomePath/MyGame.app /SomePath/MyNewGame.app via it's command line property, but it did not work.

Did you try the full filename?

FindDefaultExecutablePath('cp')+
' -R /SomePath/MyGame.app /SomePath/MyNewGame.app'

Show quoted text 5 lines
I then tried fpsystem, passing it the same string and it also fails with a 16384 error, which I've spent the last half hour searching for on Google, but it does not appear anywhere. So any help would be greatly appreciated.

Mattias

Reply by email

Dominique Louis
to Mattias Gaertner
Mattias Gaertner wrote 14 lines
On Mon, 19 May 2008 20:26:43 +0100 Dominique Louis wrote: > Hi all, > I'm passing the following command to a TProcess instance... > > cp -R /SomePath/MyGame.app /SomePath/MyNewGame.app > > via it's command line property, but it did not work. Did you try the full filename? FindDefaultExecutablePath('cp')+ ' -R /SomePath/MyGame.app /SomePath/MyNewGame.app'

That did the trick actually.

Dominique.

Reply by email