View Single Post
  #3   (View Single Post)  
Old 11th September 2010
laraaj laraaj is offline
New User
 
Join Date: Sep 2010
Posts: 2
Default

Thanks alot for your quick replay.
shc is a very lightweight program all it does is to convert a shell script into a C binary
program that runs and invoke the specified shell then feed it the encrypted commands
from the original script.
the BSD's i tried to compile the program on are all remote server i can access through ssh accounts.
one of them is Openbsd version 4.7 with gcc version 3.3.5 (propolice).
here is a part of the make file of the program i think it's already made to run on
all Unix compatible operating systems not just Linux.
Code:
# Makefile
#

INSTALL_PATH = /usr/local

# For SCO
CFLAGS = -b elf -O -D_SVID

# For IRIX
CFLAGS = -xansi -fullwarn -O3 -g0

# For Solaris
CFLAGS = -fast -xO4 -s -v -Xa

# For HPUX
CFLAGS = -Wall -O -Ae

# For OSF1
CFLAGS = -w -verbose -fast -std1 -g0

# For GNU C compiler
CFLAGS = -Wall -O6 # -pedantic

SHELL = /bin/sh

all: shc ask_for_test

shc: shc.c
	$(CC) $(CFLAGS) $@.c -o $@
i just thought i would consult some BSD expects who may have came across the
same error message before and may have any idea how to solve it or if it doesn't
have any solutions.

after checking the header file /usr/include/unistd.h line 239. "int rfork(int opts);"
i think there is something wrong with a call to rfork function.
Reply With Quote