KOS installation fails

If you have any questions on programming, this is the place to ask them, whether you're a newbie or an experienced programmer. Discussion on programming in general is also welcome. We will help you with programming homework, but we will not do your work for you! Any porting requests must be made in Developmental Ideas.
Post Reply
dcTom
DCEmu Junior
DCEmu Junior
Posts: 43
https://www.artistsworkshop.eu/meble-kuchenne-na-wymiar-warszawa-gdzie-zamowic/
Joined: Mon Feb 20, 2017 7:49 pm
Has thanked: 0
Been thanked: 0

KOS installation fails

Post by dcTom »

Hi

i was trying to install a fresh Kos on a debian system
it doesnt matter if i do it with the script or manually
it always break up at the same position

Code: Select all

$ cd /opt/toolchains/dc/kos/utils/dc-chain
$ sh download.sh
$ sh unpack.sh


after
sh download.sh
i get this error massage

Code: Select all

download.sh: 4: source: not found
download.sh: 6: print_banner: not found
download.sh: 22: Syntax error: "(" unexpected
line 4

Code: Select all

source ./scripts/common.sh
line 6

Code: Select all

print_banner "Downloader"
line 22

Code: Select all

function download()
dont know if its important but the skript tells my
it is installed "python-is-pytho2" insted of "python"
User avatar
BlueCrab
The Crabby Overlord
The Crabby Overlord
Posts: 5658
Joined: Mon May 27, 2002 11:31 am
Location: Sailing the Skies of Arcadia
Has thanked: 9 times
Been thanked: 69 times
Contact:

Re: KOS installation fails

Post by BlueCrab »

Maybe your default "sh" program isn't bash? Try running the scripts as "bash download.sh" instead of "sh download.sh".
dcTom
DCEmu Junior
DCEmu Junior
Posts: 43
Joined: Mon Feb 20, 2017 7:49 pm
Has thanked: 0
Been thanked: 0

Re: KOS installation fails

Post by dcTom »

the system is telling me that im using the bash

Code: Select all

 grep "andy" / etc / passwd
 andy:x:1000:1000:andy,,,: / home / andy: / bin / bash
i tried it with
bash download.sh
and it works,

but now i have an other problem

the dc-tool doesnt work any more

Code: Select all

./dc-tool -x game.elf -t 192.168.0.4
bash: ./dc-tool: Datei oder Verzeichnis nicht gefunden
Datei oder Verzeichnis nicht gefunden = file or folder not found
User avatar
BlueCrab
The Crabby Overlord
The Crabby Overlord
Posts: 5658
Joined: Mon May 27, 2002 11:31 am
Location: Sailing the Skies of Arcadia
Has thanked: 9 times
Been thanked: 69 times
Contact:

Re: KOS installation fails

Post by BlueCrab »

Just because you're using bash as your login shell, doesn't mean that the /bin/sh program is bash on your system. When you just say "sh somefile", it's going to run it with /bin/sh, no matter whether that is the same shell you're using or not.

As for the dc-tool problem, you are trying to run it out of the current directory there, which is probably not where the program is sitting. Use the correct path to the program (or just "dc-tool" instead of "./dc-tool" if it is in a directory in your $PATH).
dcTom
DCEmu Junior
DCEmu Junior
Posts: 43
Joined: Mon Feb 20, 2017 7:49 pm
Has thanked: 0
Been thanked: 0

Re: KOS installation fails

Post by dcTom »

even with the full path, still file or directory not found

Code: Select all

andy@debian:~$ /opt/toolchains/dc/stgframework/dc-tool 
bash: /opt/toolchains/dc/stgframework/dc-tool: Datei oder Verzeichnis nicht gefunden

but dc-tool is in this folder (see attached pic)


PS:
Someone told my the problem could be that my debain is now a 64-bit system und die dc-tool i use a 32-bit program,
in what Folder of Kos is the location of DC-Tool, so i can compile it again
Attachments
Bildschirmfoto von 2022-05-01 21-37-49.png
User avatar
BlueCrab
The Crabby Overlord
The Crabby Overlord
Posts: 5658
Joined: Mon May 27, 2002 11:31 am
Location: Sailing the Skies of Arcadia
Has thanked: 9 times
Been thanked: 69 times
Contact:

Re: KOS installation fails

Post by BlueCrab »

KOS does not include dc-tool, and it isn't built with KOS by default.

If you'd like to try building it yourself, you can get the code from the git repository at git.code.sf.net/p/cadcdev/dcload-ip (assuming you want the broadband adapter version of dc-tool/dcload).

Make sure you have libelf-dev installed from your package manager in Debian, clone that git repository mentioned earlier, go into the host-src/tool directory in it and run "make". If that works, then run "sudo make install" and it should build dc-tool and install it in /usr/local/bin (which should be in your default PATH in debian, so you'll just be able to run it as "dc-tool" without specifying a path).
dcTom
DCEmu Junior
DCEmu Junior
Posts: 43
Joined: Mon Feb 20, 2017 7:49 pm
Has thanked: 0
Been thanked: 0

Re: KOS installation fails

Post by dcTom »

thanx,

Problem is solved, 32-Bit binary version of DC-Tool was the problem, with the 64-Bit Version it works fine
Post Reply