Replacing executable file

Thread Solved

Join Date: Aug 2005
Posts: 150
Reputation: sDJh is an unknown quantity at this point 
Solved Threads: 13
sDJh sDJh is offline Offline
Junior Poster

Replacing executable file

 
0
  #1
Aug 22nd, 2008
Hello everybody,

I hope this is the right forum to post my question. It's a bit "in-between".

I am about to write an updater for a programme of mine. The updater downloads an update-file from my server that has packed all files I want to replace and executes a simple script.
Now all works file apart from the executable (programme.app/Contents/MacOS/programme), that MacOS doesn't accept as a binary file: it says its plain text.
What can I do in this case? How can I set the type of that file so that it becomes a normal executable? (How) Can I use the programme /Developer/Tools/SetFileType?

Many thanks in advance
Simon
Reply With Quote Quick reply to this message  
Join Date: Apr 2006
Posts: 5,051
Reputation: John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold John A is a splendid one to behold 
Solved Threads: 332
Team Colleague
John A's Avatar
John A John A is offline Offline
Vampirical Lurker

Re: Replacing executable file

 
1
  #2
Aug 22nd, 2008
Stupid question: have you checked to make sure that the binary has executable permissions?
"Technological progress is like an axe in the hands of a pathological criminal."

All my posts may be freely redistributed under the terms of the MIT license.
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 150
Reputation: sDJh is an unknown quantity at this point 
Solved Threads: 13
sDJh sDJh is offline Offline
Junior Poster

Re: Replacing executable file

 
0
  #3
Aug 22nd, 2008
Thanks indeed. I guess that couldt had been the problem. In the net I've seen a solution that uses SetFile, but it seems to be enough to simpy set the permission to +x.

Thank you, you helped me a lot!
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Mac tips 'n' tweaks Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC