Home  
Login
Username:

Password:

Remember me



Lost Password?

Register now!
Sections
Who's Online
60 user(s) are online (46 user(s) are browsing Forums)

Members: 1
Guests: 59

orgin, more...
Support us!
Recent OS4 Files
OS4Depot.net



« 1 2 (3) 4 5 »


Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@stonecracker

Thank you.

This is the output on my desktop (i have two setup)

amidev@DESKTOP-C279FRF:~$ ls -hal /usr/local/amiga
total 0
drwxr-xr-x 0 amidev users 512 Oct 16 20:21 .
drwxr-xr-x 0 root root 512 Oct 16 20:20 ..
drwxr-xr-x 0 amidev users 512 Oct 16 20:22 adtools
amidev@DESKTOP-C279FRF:~$ ls -hal /usr/local/amiga/adtools
total 0
drwxr-xr-x 0 amidev users 512 Oct 16 20:22 .
drwxr-xr-x 0 amidev users 512 Oct 16 20:21 ..
lrwxrwxrwx 1 root root 47 Oct 16 20:22 adtools-ppc-cyg64-20170623-404 -> /usr/local/amiga/adtools-ppc-cyg64-20170623-404
amidev@DESKTOP-C279FRF:~$ ls -hal /usr/local/amiga/adtools-ppc-uwin-20170623-404
ls: cannot access '/usr/local/amiga/adtools-ppc-uwin-20170623-404': No such file or directory
amidev@DESKTOP-C279FRF:~$

and this is from my laptop

amidev@AmigaOne:~$ ls -hal /usr/local/amiga
total 0
drwxr-xr-x 0 amidev users 512 Oct 18 21:04 .
drwxr-xr-x 0 root root 512 Oct 18 19:54 ..
drwxr-xr-x 0 amidev users 512 Oct 18 19:57 adtools
drwxrwxrwx 0 amidev amidev 512 Oct 18 22:08 adtools-ppc-uwin64-20170623-404
amidev@AmigaOne:~$ ls -hal /usr/local/amiga/adtools
total 0
drwxr-xr-x 0 amidev users 512 Oct 18 19:57 .
drwxr-xr-x 0 amidev users 512 Oct 18 21:04 ..
lrwxrwxrwx 1 root root 46 Oct 18 19:57 adtools-ppc-uwin-20170623-404 -> /usr/local/amiga/adtools-ppc-uwin-20170623-404
amidev@AmigaOne:~$ ls -hal /usr/local/amiga/adtools-ppc-uwin-20170623-404
ls: cannot access '/usr/local/amiga/adtools-ppc-uwin-20170623-404': No such file or directory
amidev@AmigaOne:~$


Perhaps this line in the first post:
ln -s /usr/local/amiga/adtools-ppc-cyg64-20170623-404 /usr/local/amiga/adtools

should be:

ln -s /usr/local/amiga/adtools/ppc-cyg64-20170623-404 /usr/local/amiga/adtools

Note the slash beetween "adtools" and "ppc-cyg64-20170623"

and the same for the UWin part, as follow

this line:
sudo ln -s /usr/local/amiga/adtools-ppc-uwin-20170623-404 /usr/local/amiga/adtools

should be:
sudo ln -s /usr/local/amiga/adtools/ppc-uwin-20170623-404 /usr/local/amiga/adtools

Just a guess.

If this is not correct, i will edit the post to avoid confusion



Edited by AmigaBlitter on 2017/10/19 16:52:54
_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@stonecracker

I have prepared a simple script to auto install the environment.

https://drive.google.com/file/d/0B1kXS ... wM2hFcDA/view?usp=sharing

from the UWin home directory run:

chmod a+x amidev.sh

then run

sudo ./amidev.sh

Should do most of the work automatically.

reporting here the content of the file for completeness.
Any improvement is welcome.

cd $home
clear
echo ENTER YOUR SUDO PASSWORD:
sudo
sudo apt-get -y install bison
sudo apt-get -y install bzip2
sudo apt-get -y install flex
sudo apt-get -y install gcc
sudo apt-get -y install g++
sudo apt-get -y install git
sudo apt-get -y install git-svn
sudo apt-get -y install libgmp-dev
sudo apt-get -y install libmpc-dev
sudo apt-get -y install libmpfr-dev
sudo apt-get -y install lhasa
sudo apt-get -y install make
sudo apt-get -y install nano
sudo apt-get -y install python-minimal
sudo apt-get -y install python3
sudo apt-get -y install python3-dev
sudo apt-get -y install texinfo
sudo apt-get -y install unzip
sudo apt-get -y install zip
ln -s /usr/local/amiga/adtools-ppc-uwin64-20170623-404 /usr/local/amiga/adtools
export PATH=$PATH:~/adtools/bin:/usr/local/amiga/adtools/bin
sed 'export PATH=$PATH:~/adtools/bin:/usr/local/amiga/adtools/bin' ~/.bashrc
sudo mkdir /usr/local/amiga
sudo chown amidev:users /usr/local/amiga
sudo mkdir /usr/local/amiga/adtools
sudo chown amidev:users /usr/local/amiga/adtools
echo GCC VERSION
gcc -v
echo G++ VERSION
g++ -v
cd $home
git clone https://github.com/sba1/adtools.git
cd ~/adtools/gild
git submodule init
git submodule update
cd ~/adtools
gild list
gild clone
gild checkout binutils 2.23.2
gild checkout coreutils 5.2
gild checkout gcc 5
make -C native-build gcc-cross CROSS_PREFIX=/usr/local/amiga/adtools-ppc-uwin64-20170623-404
cd ~
ppc-amigaos-gcc -v

note: replace amidev with your own unix user name

_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just popping in
Joined:
8/8 20:17
From Canada
Posts: 32
@AmigaBlitter:

Not sure what's going on with your setups. It's like the symlinks are all wonky. My output looks like this:


$ ls -hal /usr/local/amiga/
total 5.0K
drwxr-xr-x+ 1 sc None 0 Oct 19 23:23 .
drwxr-xr-x+ 1 sc None 0 Oct 4 05:10 ..
lrwxrwxrwx 1 sc None 47 Oct 5 05:03 adtools -> /usr/local/amiga/adtools-ppc-cyg64-20170623-404
lrwxrwxrwx 1 Administrators None 30 Oct 5 07:26 adtoolsln -> adtools-ppc-cyg64-20170623-404
drwxr-xr-x+ 1 sc None 0 Oct 4 06:59 adtools-ppc-cyg64-20170623-404


Note, the "adtoolsln" is another symlink that was created as part of my Visual Studio 2017 guide. That is, there are 2 symlinks pointing to the same "adtools-ppc-cyg64-20170623-404" directory -- one usable from Cygwin, the other from Windows.

For the purposes of this post, however, I'm not sure what's going on with your build.

And my Cygwin setup was done with the command, as-originally-posted, namely:

ln -s /usr/local/amiga/adtools-ppc-cyg64-20170623-404 /usr/local/amiga/adtools

Or for Uwin:

sudo ln -s /usr/local/amiga/adtools-ppc-uwin64-20170623-404 /usr/local/amiga/adtools


I have a suggestion: redo everything from scratch. That is, follow the instructions from the outset by deleting or renaming the /usr/local/amiga directory and starting from step 1.

I think I've inadvertently caused you some mis-steps in the setup because I've been editing/updating the instructions along the way...and I think you've got a versioning thing going on because of the pathnames/etc I see. Apologies.



   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@stonecracker

Nothing to apologize.

The tutorial is great.

I even automated the process of installation thanks to your tips.

Moreover i re-opened my Linux Window (what a word's joke)

_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just popping in
Joined:
8/8 20:17
From Canada
Posts: 32
For ease of reference, in case you're one of those readers who, like me, tend to just hop to the end of a long topic chain to see where everything has landed:


The first/originating post in this topic chain has now been extensively updated again. Most of the typos/errors/clarifications should be in there.

I also have 2 follow-on guides to this one.

1st: A guide showing how to actually use the Cygwin version of these adtools inside Visual Studio 2017

http://www.amigans.net/modules/xforum ... m=25&topic_id=7639&order=


2nd: A guide showing how to actually use either the Cygwin or UWin versions of these adtools from your Cygwin or UWin bash command-lines instead of using an IDE.

http://www.amigans.net/modules/xforum ... m=25&topic_id=7654&order=


   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
Sigh,

i reinstalled again from scratch, followed all the steps and again, it doesn't work

_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@stonecracker
amidev@AmigaOne:~/adtools$ ppc-amigaos-gcc -v
ppc-amigaos-gcc: command not found
amidev@AmigaOne:~/adtools$

I think that the error resides in the make command line and in a symbolic link

[fixed]


Edited by AmigaBlitter on 2017/11/1 17:07:31
_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@stonecracker

gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/5/lto-wrapper
Target: x86_64-linux-gnu

Is this correct?

_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@stonecracker

Last time i succeded installing the Uwin environment, i was able to compile for AmigaOS. I tried to compile the SDL2 and the compilation was ok. Just the SDK 53_30 was needed.

Now i reinstalled the UWin environment with the SDK 53_30, following your instructions.

Btw, when i try to compile the SDL2, as soon as compilation starts, i get an error: can't find -strict -align (sort of).

I will post the correct error message asap.

Someone told me that the the correct compiler is not executed in this case.

Any hint?



_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just can't stay away
Joined:
2007/1/26 21:48
From New Zealand
Posts: 1850
@AmigaBlitter

Are you sure that the SDL2 build scripts are using ppc-amigaos-gcc (and it's sub-executables)? Although, if it were using the native compiler that error still shouldn't occur. The other question is, which version of GCC for AmigaOS did you build in your UWin enivonment?

Hans

_________________
http://hdrlab.org.nz/ - Amiga OS 4 projects, programming articles and more.
https://keasigmadelta.com/ - more of my work
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Not too shy to talk
Joined:
2007/7/14 20:30
From Lothric
Posts: 267
https://gcc.gnu.org/onlinedocs/gcc-5.5 ... mmary.html#Option-Summary -mstrict-align option is available for 3 HW platforms (one of them is PowerPC). It's clear to me that a wrong compiler is used here.

AmigaBlitter: if ppc-amigaos-gcc command cannot be executed (as you write above), or it's somehow linked to the wrong compiler, then you cannot crosscompile.

   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
Thank you for the replies.

I think that the configure script and make are picking the wrong compiler.

Something went wrong during the UWin environment setup. I tried all my best but, i'm sure, i get lost somewhere during the initial configuration. As pe SDL2 packages, i'm sure it works correctly (hey, capehill is doing the magic here). I already correctly configured and (almost) compiled with my previous UWin installation. Now i'm trying to reinstall everything from scratch, following the correct steps.

_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@AmigaBlitter

I reinstalled again UWin, repeating all the steps. Still have the problem compiling SDL2. It's seems that the wrong cvompiler is used.

_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just can't stay away
Joined:
2007/1/26 21:48
From New Zealand
Posts: 1850
@AmigaBlitter

Are you telling the configure script to cross-compile? I can't remember how that's done, but it'll default to the native compiler unless told otherwise.

Hans

_________________
http://hdrlab.org.nz/ - Amiga OS 4 projects, programming articles and more.
https://keasigmadelta.com/ - more of my work
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@Hans

Yes, i've done by typing ./configure --host=ppc-amigaos

It worked only one time, bu sadly i uninstalled that version.


From stonecracker suggestions:

"Hmmm. Did the executables get built?

If you "ls -hal /usr/local/amiga/adtools/bin"

What do you see? I'm wondering if there's any ppc-amigaos-gcc executable even there/built."

If i try i get:

amidev@AmigaOne:~$ ls -hal /usr/local/amiga/adtools/bin
ls: cannot access '/usr/local/amiga/adtools/bin': No such file or directory

So it seems that the executables never built.

But... if i type ppc-amigaos-gcc -v i get

Using built-in specs.COLLECT_GCC=ppc-amigaos-gcc
COLLECT_LTO_WRAPPER
=/usr/local/amiga/adtools-ppc-uwin64-20170623-404/libexec/gcc/ppc-amigaos/5.4.0/lto-wrapper 
Target
ppc-amigaos 
Configured with
: /home/amidev/adtools/gcc/repo/configure --with-bugurl=https://github.com/sba1/adtools/issues --with-pkgversion='adtools build 5.4.0' --target=ppc-amigaos --prefix=/usr/local/amiga/adtools-ppc-uwin64-20170623-404 --enable-languages=c,c++ --enable-haifa --enable-sjlj-exceptions --disable-libstdcxx-pch --disable-tlsThread model: singlegcc version 5.4.0 (adtools build 5.4.0



_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just can't stay away
Joined:
2007/1/26 21:48
From New Zealand
Posts: 1850
@AmigaBlitter

Quote:
Yes, i've done by typing ./configure --host=ppc-amigaos

Just looked up some docs, and it should be something like:
./configure --target=ppc-amigaos

Note the --target, instead of --host. --host is supposed to indicate the platform that will be used to compile, whereas you want to set the platform that it will build for.

I'm not 100% sure about this though, because some examples use the --host and --build parameters instead.

Hans

_________________
http://hdrlab.org.nz/ - Amiga OS 4 projects, programming articles and more.
https://keasigmadelta.com/ - more of my work
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just popping in
Joined:
2008/4/30 4:49
From UK
Posts: 168
@Hans

Anyone trying BEBBOs toolchain ?:

https://github.com/bebbo/amigaos-cross-toolchain


This would be the default AmigaOS 3.x, AROS toolchain to keep a set standard across Amiga systems in 2017+.

Stefan "Bebbo" Franke's fork of Krystian Bacławski's AmigaOS Cross-Compiler Toolchain.

Tested on multiple machines,Windows Cygwin 32 bit, Ubuntu 32/64 bit and CentOs 64 bit, & Mac.

http://eab.abime.net/showthread.php?t=85474

A Docker is available:
Dockerfile for Stefan "Bebbo" Franke's fork of Krystian Bacławski's AmigaOS Cross-Compiler Toolchain.

https://github.com/sebastianbergmann/docker-amigaos-cross-toolchain

docker run -v $HOME:/host -it sebastianbergmann/m68k-amigaos-bebbo \
m68k-amigaos-gcc /host/hello.c -o /host/hello -noixemul

docker run -v $HOME:/host -it sebastianbergmann/m68k-amigaos-bebbo \
vasm -Fhunkexe -o /host/hello /host/hello.s

run the Amiga software in Linux using Docker :

docker-execute-amiga helloworld

or Dockerized emulation using vamos eg (compile & run an AmigaOS C/C++ compiler from the internet/server !! )

docker run -v $HOME:/host sebastianbergmann/amitools:latest \
vamos -C 68020 /host/hello



Details

ppc-amigaos target:

gcc 4.2.4, g++ 4.2.4, binutils 2.18 (assembler, linker, etc.)
newlib, clib 2.2
AmigaOS headers & libraries & autodocs (for AmigaOS 4.1)

AmigaOS, 68k
binutils 2.9.1 & 2.14, libnix 2.2, libm 5.4

AmigaOS 3.x toolchain, vbcc toolchain (vasm, vlink & C standard library)
Headers, libraries, autodocs, for AmigaOS 3.9

MacOSX users : Require MacPorts or Homebrew installed.

Prerequisites

You have to have following packages installed in your system:

GNU gcc 5.x 32-bit version! or Clang
Python 2.7.x
libncurses-dev
python-dev 2.7
GNU make 4.x
perl 5.22
git
GNU patch
GNU gperf
GNU bison

Windows 10 64-bit with Cygwin 32bit

Install cygwin via setup.exe and add wget. Then open cygwin shell and:

wget https://raw.githubusercontent.com/tran ... en/apt-cyg/master/apt-cyg
install apt-cyg /bin
apt-cyg install gcc-core gcc-g++ python git perl-Pod-Simple gperf patch automake make makedepend bison flex libncurses-devel python-devel gettext-devel libgmp-devel libmpc-devel libmpfr-devel



Ubuntu 16.04 LTS 32-bit (gcc 5.4.0)

sudo apt-get install git gcc g++ python-dev gperf patch automake make bison libncurses-dev gettext libgmp-dev libmpc-dev libmpfr-dev
git clone https://github.com/bebbo/amigaos-cross-toolchain

Build

git clone git://github.com/bebbo/amigaos-cross-toolchain.git cd amigaos-cross-toolchain

./toolchain-m68k --prefix=/opt/m68k-amigaos build

optional -threads, AHI, CyberGraphX, Magic User Interface, etc

/toolchain-m68k --prefix=/opt/m68k-amigaos install-sdk ahi cgx mui

Failed ? send email and log to report and fix issues & asm optimizations. Donations welcome.

./toolchain-m68k build 2>&1 | tee build.log

cleanup build before use
rm -rf .build-m68k
rm -rf /opt/m68k-amigaos




Edited by angelheart on 2017/11/8 16:05:15
Edited by angelheart on 2017/11/8 16:38:04
Edited by angelheart on 2017/11/8 16:40:14
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2006/11/22 17:57
From Italy, Rome
Posts: 528
@Hans

Thank you for the info.

I will try in the next days.

Just to add some info, i had a working installation and using -host=ppc-amigaos worked fine. I uninstalled because the SDK 24 version 54_24 and not 54_30. Using the option --disable-altivec the final configure report told me "no assembly math", while now i get mmx, 3dnow, sse, sse2 that looks pretty x86ish.


_________________
Retired
   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Quite a regular
Joined:
2009/4/28 3:57
From Adelaide, Australia
Posts: 816
@Hans

--target is used to tell the compiler what architecture to compile for, not to choose the compiler itself. So in that case, you're asking an x86 compiler to make a ppc-amigaos architecture binary. It's not able to do that.

--host is used to specify which hosted environment/toolchain to use, like a prefix. It's confusing.

--build is used to specify the architecture of the actual system you're doing this all on (I've not had to use this).

https://gcc.gnu.org/onlinedocs/gccint/Configure-Terms.html

So, the correct flag is --host=ppc-amigaos

   Report Go to top

Re: Building Cross-Compiling adtools for Amiga OS4 PowerPC (ppc) with Cygwin/Bash on Ubuntu on Windows
Just can't stay away
Joined:
2006/11/30 11:30
From Finland
Posts: 1526
@MickJT

Quote:

--host is used to specify which hosted environment/toolchain to use, like a prefix. It's confusing.

--build is used to specify the architecture of the actual system you're doing this all on (I've not had to use this).


IIRC the only difference between --host and --build is that --host is to be used for cross compiling and --build is to be used only if you are doing a native build.

   Report Go to top


« 1 2 (3) 4 5 »



[Advanced Search]


Powered by XOOPS 2.0 © 2001-2016 The XOOPS Project