PDA

View Full Version : Remotejoy on Linux (*buntu Intrepid)



lingenfr
11-16-2008, 11:07 AM
I am running Intrepid (2.6.27-7-generic) and trying to get RJ running. I have tried to follow instructions at the following locations:

http://forums.ps2dev.org/viewtopic.php?p=67262&sid=e4c9c13eaba175f91099d251b2303ab2
http://www.ngine.de/index.jsp?pageid=4292
http://www.guztech.nl/index.php?option=com_content&view=article&id=49:setting-up-the-psptoolchain&catid=38:psp&Itemid=56

I have done quite a bit of additional searching and I believe that the solution was to downgrade gcc. If that is the only way to get it to work, I expect that I will skip it. Or I am going to use a separate machine or VM.

Has anyone been successful at getting Remotejoy to work on linux and would be willing to provide some advice? Thanks.

tinman
11-16-2008, 05:18 PM
Yes, and it's quite easy :)

It's called "gcc_select", it's part of Mac OS X, because different versions of GCC are needed a lot.

I highly recommend using the -n option so you see what has been "ln'ed"


## configuration time options
PREFIX=__PREFIX__
NAME=__NAME__
TOOL=${NAME}_select
CONFPATH=${PREFIX}/etc/select/${NAME}
VERSION=__VERSION__


## GLOBALS
# dont actually execute, just show what would have been done
noexec=0
# enforce action
force=0
# skip check for required rights
isroot=0
# perform "install" mode (for initial destroot)
inst_mode=0
DESTDIR=""


# print the usage of this tool
usage() {
echo "usage: ${TOOL} [-n] [-f] [-r] [-h] [-v] version"
echo ""
echo "-n Show commands to do selection but do not execute them."
echo "-f Ensure the links are correct for the specified version"
echo " even if it maches the current default version."
echo "-h Display this help info."
echo "-r Skip test for necessary rights."
echo "-v Display version of ${0}."
echo "-l List available options for version."
echo "-i path Install mode to perform an initial selection in path."
echo ""
}

# print the version of this tool
version() {
echo "${TOOL} v${VERSION}"
}

# list all (currently) available versions
list_version() {
echo "Available versions:"
echo $(ls -1 ${CONFPATH} | grep -v base)
}

# test if a particular version is available
version_is_valid() {
for version in $(ls -1 ${CONFPATH} | grep -v base); do
if [ ${1} == ${version} ]; then
return 0
fi
done
return 1
}

# perform an action (command) or just display it
action() {
if [ "rm" == ${1} ]; then
if [ 1 == ${noexec} ]; then
echo "rm -f ${2}"
else
rm -f ${2}
fi
elif [ "ln" == ${1} ]; then
if [ 1 == ${noexec} ]; then
echo "ln -sf ${2} ${3}"
else
ln -sf ${2} ${3}
fi
else
return 1
fi
}

# change symlinks
select_version() {
# count the number of errors
local error=0
local i=1
local empty=0
echo "Selecting version \"${1}\" for ${NAME}"
for target in $(cat ${CONFPATH}/base); do
src=$(head -n ${i} ${CONFPATH}/${1} | tail -n 1)

empty=0
# test if line starts with '-' -> dont link, just rm original
if [ "-" == $(echo ${src} | colrm 2) ]; then
# source is unavailable for this file
action "rm" "${DESTDIR}${PREFIX}/${target}"
elif [ "/" == $(echo ${src} | colrm 2) ]; then
# source has an absolute path
action "ln" "${src}" "${DESTDIR}${PREFIX}/${target}"
else
# source has relative path
action "ln" "${PREFIX}/${src}" "${DESTDIR}${PREFIX}/${target}"
fi
let "error = error + ${?}"
let "i = i + 1"
done
return ${error}
}


if [ ${#} == 0 ]; then
usage
exit 2
fi

# parse command line args
args=$(/usr/bin/getopt i:fhnlrv $*)
set -- ${args}
for i; do
case "${i}" in
-h)
usage; exit 0;;
-n)
noexec=1; shift;;
-f)
force=1; shift;;
-l)
list_version; exit 0;;
-r)
isroot=1; shift;;
-v)
version; exit 0;;
-i)
inst_mode=1; DESTDIR=${2}; shift; shift;;
--)
shift; break;;
esac
done

# install mode - bypass all checks and add DESTDIR
if [ "1" = "${inst_mode}" ]; then
echo "install mode: destroot: \"${DESTDIR}\""
CONFPATH=${DESTDIR}${CONFPATH}
select_version ${1}
exit ${?}
fi

# test if chosen version is available
version_is_valid $1
if [ 0 != ${?} ]; then
echo "version \"$1\" is invalid!"
exit 4
fi

# execute selection
select_version ${1}
if [ 0 != ${?} ]; then
echo "there were ${?} errors selecting version \"${version}\"!"
exit 5
fi

exit 0

lingenfr
11-16-2008, 06:50 PM
Yes, it looks like a neat app, but doesn't seem to be available for linux.

tinman
11-18-2008, 03:04 AM
Yes, it looks like a neat app, but doesn't seem to be available for linux.

So that means it will not work? To set it up in Linux:

1st look at my gcc config files. (do not edit the base file)

To see what gcc versions you have type gcc then press tab 2 times.

Type:


which gcc-*.*

The *.* would be the versions you have. (like gcc-4.2)

Copy the folder from the attached file to the /opt folder.


./configure


make install

An example config:


/usr/bin/gcc-4.2
/usr/bin/cpp-4.2
/usr/bin/c++-4.2
/usr/bin/g++-4.2
/usr/bin/gcov-4.2

After you do this correctly, gcc_select will link the files to gcc, cpp, g++, etc...

The linking of the files will make gcc also use the libs for that version.

I have done this on my Linux system with no problems.

Note: Only keep the base file, the rest are examples. Delete them after you get how this works.

lingenfr
11-19-2008, 06:39 AM
gcc<tab><tab> returned:

gcc gcc-4.1 gcc-4.2 gcc-4.3 gccbug-4.1 gccmakedep


I am trying to find the page again that identified what version was needed. Most of the information appears to be mac specific, so I am trying to find some information I found a week or so ago that said a different gcc version was required.

lingenfr
11-23-2008, 11:21 AM
Hey tinman,

I found the page that I think outlines what I need to do at:

http://ubuntuforums.org/showthread.php?p=6230623

Specifically it says:

Use gcc 4.2 and g++ 4.3 to compile the toolchain.

Tried it, still no joy. Continuing to try different things. It would be nice if someone is knowledgeable if they would post an up-to-date howto for RJ on Linux. Preferably *buntu.

tinman
11-25-2008, 07:19 PM
Hey tinman,

I found the page that I think outlines what I need to do at:

http://ubuntuforums.org/showthread.php?p=6230623

Specifically it says:

Use gcc 4.2 and g++ 4.3 to compile the toolchain.

Tried it, still no joy. Continuing to try different things. It would be nice if someone is knowledgeable if they would post an up-to-date howto for RJ on Linux. Preferably *buntu.

It seems that remotejoy has a few issues with Linux. I somehow can get it running 90% (just need a "F5" from time to time) in Linux, I made a half ass'ed guide here (http://irshell.org/site/index.php?option=com_fireboard&Itemid=2&func=view&id=14079&catid=19) for x64 Linux users. 32-Bit binaries are available in the download section.

lingenfr
12-07-2008, 10:18 AM
Thanks for the attempt tinman, but that is not enough information to help me. Following ideas from ubuntuforums and ps2dev forums, I got everything compiled. I can run usbhostfs_pc and it connects, pspsh does its thing and even remotejoy runs to a black screen. However, when I type vsh reset, the PSP eventually turns off. All of the instructions are so fragmented and incomplete that it is almost like a scavenger hunt. Still trying...