LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 06-25-2004, 06:19 PM   #1
Anon123
LQ Newbie
 
Registered: Jun 2004
Posts: 6

Rep: Reputation: 1
Convert from shell script to binary?


How can I compile my shell script using a GCC or something so it is binary, and users cannot view the source. I need to do it remotely via shell/bash on a RH9, Fedora, or FreeBSD 5.2.x box (I have multiple servers).

Thanks in advance.
 
Old 06-25-2004, 06:34 PM   #2
fluppi
Member
 
Registered: Oct 2003
Location: Switzerland (Europe)
Distribution: OpenSuSE, RedHat, Knoppix, IRIX + MacOSX
Posts: 198

Rep: Reputation: 30
An ugly but quick and dirty possibility is, to embed your script in a C program through system calls.
Like execl("echo Hello");

Otherwise, can't you took away the rights to your scripts, so other can't read them ?
 
Old 06-25-2004, 07:09 PM   #3
SciYro
Senior Member
 
Registered: Oct 2003
Location: hopefully not here
Distribution: Gentoo
Posts: 2,038

Rep: Reputation: 51
why not just rewrite the entire program using c or something? (after all, scripts are scripts, not really meant to be binary)
 
Old 06-25-2004, 07:28 PM   #4
Anon123
LQ Newbie
 
Registered: Jun 2004
Posts: 6

Original Poster
Rep: Reputation: 1
Quote:
Originally posted by SciYro
why not just rewrite the entire program using c or something? (after all, scripts are scripts, not really meant to be binary)
And how would I go about doing that?
 
Old 06-26-2004, 06:53 AM   #5
SciYro
Senior Member
 
Registered: Oct 2003
Location: hopefully not here
Distribution: Gentoo
Posts: 2,038

Rep: Reputation: 51
open up a console, and load up your favorite text editor, and try not to get to bored
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to convert binary text file from Windows marie@dk Linux - Software 2 10-12-2005 04:17 AM
shell script provides an error that a binary operator is required max_rsr Linux - General 1 03-12-2005 09:26 AM
Writing shell script called "convert" bluewolf Programming 3 02-04-2003 11:52 PM
How would one convert a file into binary? MasterC General 8 01-21-2003 11:50 PM
how to convert a text file into shell script meng_en Linux - General 9 10-15-2002 11:46 PM


All times are GMT -5. The time now is 02:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration