RetroBSD

2.11BSD operating system for microcontrollers
It is currently Wed Dec 02, 2020 6:56 pm

All times are UTC




Post new topic Reply to topic  [ 79 posts ]  Go to page 1, 2, 3, 4  Next
Author Message
PostPosted: Fri Feb 20, 2015 10:55 am 
Contributor
User avatar

Joined: Thu Nov 08, 2012 7:04 am
Posts: 2401
Location: Rapa Nui
CONTINUOUS UPDATE !!
As of Oct 15 2015
Do update LiteBSD (git pull) and pic32prog (git pull) when using an earlier version of this setup! There are important fixes done every day and night !
No warranties of any kind, do it at your own risk..


Thanks to Serge and Matt I come to this guide..


1. I did a fresh install of Ubuntu 14.04 (warning: see the tools for 32 or 64bit below)

2. Creating Kernel, Unix system and Filesystem

Tools required for 32bit linux:
Code:
cd $HOME

sudo apt-get install git exuberant-ctags bmake bison byacc flex libfuse-dev

git clone https://github.com/sergev/LiteBSD.git

git clone https://github.com/sergev/pic32prog.git

wget https://sourcery.mentor.com/GNUToolchain/package12725/public/mips-sde-elf/mips-2014.05-24-mips-sde-elf-i686-pc-linux-gnu.tar.bz2

sudo tar xvjf mips-2014.05-24-mips-sde-elf-i686-pc-linux-gnu.tar.bz2 -C /usr/local

export BSDSRC=$HOME/LiteBSD

export MIPS_GCC_ROOT=/usr/local/mips-2014.05

export MAKESYSPATH=$BSDSRC/share/mk-pic32


For 64bit linux do install above tools and in addition:
Code:
cd $HOME
sudo apt-get install gcc-multilib libc6-i386


Must be done: Go to your home directory, in your file browser do Ctrl-H and you will see the hidden files, open and edit the .bashrc one and do add at the end of it the following exports:
Code:
export BSDSRC=$HOME/LiteBSD
export MIPS_GCC_ROOT=/usr/local/mips-2014.05
export MAKESYSPATH=$BSDSRC/share/mk-pic32


In case you took a nap (update your LiteBSD distribution to the latest one):
Code:
cd $BSDSRC
git pull


In case you want to clean before the build:
Code:
cd $BSDSRC
bmake clean


Build the Kernel (will be flashed into the pic32MZ chip):
Code:
cd $BSDSRC
bmake kernel

You will get in LiteBSD/sys/compile/WIFIRE.pic32/vmunix.elf (and .hex) - the kernel binary.

In order to build for the Majenko's 'SDZL' board do change in the top Makefile:
Code:
BOARD  ?= SDZL.pic32

You will get in LiteBSD/sys/compile/SDZL.pic32/vmunix.elf (and .hex) - the kernel binary.

Build the Unix system (will be placed on the SDcard's filesystem):
Code:
cd $BSDSRC
bmake build

or, not to see the outputs in the terminal (will be logged into log.txt) but the errors, when any:
Code:
bmake build >& log.txt

The good result shall be (after ~2-4minutes)
Code:
$ bmake build >& log.txt
$


Create the SDcard image of the filesystem (LiteBSD/sdcard.img ~348.1MB):
Code:
cd $BSDSRC
bmake fs


3. Flashing the Kernel into the pic32MZ chip

You may find the pic32prog programming utility in $HOME/pic32prog/linux32/pic32prog, create an symbolic link to it -
32bit linux:
Code:
sudo ln -s $HOME/pic32prog/linux32/pic32prog /usr/bin/pic32prog

64bit linux:
Code:
sudo ln -s $HOME/pic32prog/linux64/pic32prog /usr/bin/pic32prog


Upload the Kernel to the pic32MZ's flash via serial (there must be the bootloader installed):
Code:
cd $BSDSRC
bmake load


Above command uploads the Kernel into the pic32MZ via Serial Uart - an USB/serial dongle for example. The prerequisite here is to have the bootloader installed - it comes mostly with the board (consult your board maker, the SDZL's one is attached with kind permission). You need to activate the bootloader however, for example by resetting the pic32MZ while keeping "prog" button pressed down (ie. SDZL board). It will upload the stuff (115k2 8N1) into the chip then. In retrobsd the bootloader works usually via USB, we do not have this option ready with LiteBSD yet.

The Rx/Tx pins on the SDZL board are:
Code:
Dongle SDZL PIC32 Description
-----------------------------
RXD    A8   RB6   U2TX
TXD    A9   RB7   U2RX


You may upload from windoze too - I did it from win7 via my Bluetooth HC-05:
Code:
pic32prog.exe -d com5 vmunix.hex


Do not flash the Kernel directly into the chip (via picki2 or pickit3) - it will not work. The pic32MZ config bits are set within the bootloader !

Since today you may flash the bootloader into pic32MZ via pickit2 or pickit3:
Code:
pic32prog bootloader.hex

When the SDZL's bootloader is activated the blue LED starts blinking. Then you may start upload the Kernel as described above.

4. Making the SDcard with Unix

Copy filesystem image onto your SDcard named "sdb" ("sdx" could be a different device on your linux box - double check!):
Code:
cd $BSDSRC
bmake installfs SDCARD=/dev/sdb


5. In final, you may get (SDZL board):


Code:
Copyright (c) 1982, 1986, 1989, 1991, 1993
        The Regents of the University of California.  All rights reserved.

4.4BSD-Lite build 0 compiled 2015-02-20
    sergev@ubuntu-sergev:LiteBSD/sys/compile/SDZL.pic32
cpu: PIC32MZ2048ECG064 rev A5, 200 MHz
oscillator: system PLL div 1:6 mult x50
cache: 16/4 kbytes
real mem = 512 kbytes
avail mem = 348 kbytes
using 18 buffers containing 73728 bytes of memory
spi1 at pins sdi=D14/sdo=C1/sck=D1
spi2 at pins sdi=G7/sdo=G8/sck=G6
spi3 at pins sdi=B10/sdo=C4/sck=B14
spi4 at pins sdi=F5/sdo=G0/sck=D10
uart1 at pins rx=D2/tx=D3, interrupts 112/113/114
uart2 at pins rx=B7/tx=B6, interrupts 145/146/147, console
sd0 at port spi2, pin cs=G9
sd0: type SDHC, size 3914752 kbytes, speed 16 Mbit/sec
sd0a: partition type b7, sector 2, size 204800 kbytes
sd0b: partition type b8, sector 409602, size 32768 kbytes
sd0c: partition type b7, sector 475138, size 102400 kbytes
bpf: lo0 attached
WARNING: preposterous clock chip time -- CHECK AND RESET THE DATE!

starting file system checks.
/dev/rsd0a: file system is clean; not checking
starting network
clearing /tmp
standard daemons: update.
Fri Feb 20 17:53:51 PST 2015


4.4BSD-Lite (bsd.net) (console)

login: root
Last login: Fri Feb 20 17:53:23 on console
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
        The Regents of the University of California.   All rights reserved.

4.4BSD-Lite UNIX #1: Fri Apr 01 00:00:00 PDT 1994

Welcome to 4.4BSD-Lite!

erase ^H, kill ^U, intr ^C status ^T
Don't login as root, use the su command.
# df
Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/sd0a      200860    49488   135300    27%    /
# ls -l /
total 48
-rw-rw-r--  1 root  wheel   684 Feb 20 13:04 .cshrc
-rw-rw-r--  1 root  wheel   286 Feb 20 13:04 .profile
-rw-rw-r--  1 root  wheel  3425 Feb 20 13:04 COPYRIGHT
drwxrwxr-x  2 root  wheel   512 Feb 20 17:51 bin
drwxrwxr-x  3 root  wheel  1536 Feb 20 17:51 dev
drwxrwxr-x  3 root  wheel  1024 Feb 20 17:51 etc
drwxrwxr-x  2 root  wheel   512 Feb 20 17:51 home
drwxrwxr-x  2 root  wheel   512 Feb 20 17:53 root
drwxrwxr-x  2 root  wheel  1024 Feb 20 17:51 sbin
drwxrwxrwt  2 root  wheel   512 Feb 20 17:51 tmp
drwxrwxr-x  9 root  wheel   512 Feb 20 17:51 usr
drwxrwxr-x  7 root  wheel   512 Feb 20 17:51 var
# ps alx
  UID   PID  PPID CPU PRI NI   VSZ  RSS WCHAN  STAT TT       TIME COMMAND
    0     0     0   0 -18  0     0    0 schedu DLs  ??    0:00.01 (swapper)
    0     1     0   2  10  0   168    0 wait   Ss   ??    0:00.15 /sbin/init
    0     2     0  15 -18  0     0    0 -      RL   ??    0:01.58 (pagedaemon)
    0    28     1   0  18  0    20    0 pause  SWs  ??    0:00.00 update
    0    35     1   3  10  0   248   80 wait   Ss    2    0:01.11 -sh (sh)
    0    39    35   2  28  0   200   88 -      R+    2    0:00.07 (ps)
# halt -q
syncing disks... done
halted


Attachments:
chipKIT-Bootloaders.X.production.zip [5.75 KiB]
Downloaded 794 times

_________________
Pukao Hats Cleaning Services Ltd.
Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 8:45 pm 
User avatar

Joined: Mon Nov 12, 2012 3:17 pm
Posts: 164
Location: Bratislava, Slovakia
Consider me as complete beginner. I followed your guide and quickly finished on this
Code:
jarin@plechac:~$
jarin@plechac:~$ cd $BSDSRC
jarin@plechac:~/LiteBSD$ cd $MIPS_GCC_ROOT
jarin@plechac:/usr/local/mips-2014.05$ cd $MAKESYSPATH
jarin@plechac:~/LiteBSD/share/mk-pic32$ cd $BSDSRC
jarin@plechac:~/LiteBSD$ bmake kernel
bmake -Cusr.sbin/config
byacc -d config.y
byacc: 12 reduce/reduce conflicts.
mv y.tab.c config.c
gcc  -Werror -c config.c
gcc  -Werror -c main.c
flex  lang.l
mv lex.yy.c lang.c
gcc  -Werror -c lang.c
gcc  -Werror -c mkioconf.c
gcc  -Werror -c mkmakefile.c
gcc  -Werror -c mkglue.c
gcc  -Werror -c mkheaders.c
gcc  -Werror -c mkswapconf.c
gcc  -o config config.o main.o lang.o mkioconf.o mkmakefile.o mkglue.o mkheaders.o mkswapconf.o -ll
nroff -man config.8 > config.0
(cd sys/mips/conf; ../../../usr.sbin/config/config -g WIFIRE.pic32)
Don't forget to run "make depend"
bmake -Csys/compile/WIFIRE.pic32 depend clean
ln -s ../../mips/include machine
gcc -m32 -g -nostdinc -fno-builtin -I. -I../.. -I. -DWIFIRE -DPIC32MZ -DBUTTON2=0x14 -DBUTTON1=0x15 -DSD_LED=0x7f -DINET -DPROCFS -DFDESC -DKERNFS -DUNION -DFFS -DFIFO -DCONS_MINOR=3 -DCONS_MAJOR=17 -DHZ=100 -DCPU_KHZ=200000 -DBUFPAGES=18 -DNBUF=18 -DNMBCLUSTERS=16 -DNKMEMCLUSTERS=32 -DDEBUG -DDIAGNOSTIC -DDEVPAGER -DVNODEPAGER -DSWAPPAGER -DTIMEZONE=480 -DDST=1 -DMAXUSERS=2 -o genassym ../../mips/pic32/genassym.c
/usr/bin/ld: cannot find crt1.o: No such file or directory
/usr/bin/ld: cannot find crti.o: No such file or directory
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc.a when searching for -lgcc
/usr/bin/ld: cannot find -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find -lc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc.a when searching for -lgcc
/usr/bin/ld: cannot find -lgcc
/usr/bin/ld: skipping incompatible /usr/lib/gcc/x86_64-linux-gnu/4.8/libgcc_s.so when searching for -lgcc_s
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: cannot find crtn.o: No such file or directory
collect2: error: ld returned 1 exit status
*** Error code 1

Stop.
bmake[1]: stopped in /home/jarin/LiteBSD/sys/compile/WIFIRE.pic32
*** Error code 1

Stop.
bmake: stopped in /home/jarin/LiteBSD
jarin@plechac:~/LiteBSD$

Seems like the exported paths are OK, but it apparently tries to look for correct files in wrong directories
Code:
/usr/bin/ld: cannot find crt1.o: No such file or directory

Honestly, I'm just trying to find my way throug the makefile maze, not very successful at the moment.

_________________
http://jaromir.xf.cz/
https://hackaday.io/jaromir/


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 9:03 pm 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
Hi Jaromir,
jaromir wrote:
gcc -m32 -g -nostdinc -fno-builtin -I. -I../.. -I. -DWIFIRE -DPIC32MZ -DBUTTON2=0x14 -DBUTTON1=0x15 -DSD_LED=0x7f -DINET -DPROCFS -DFDESC -DKERNFS -DUNION -DFFS -DFIFO -DCONS_MINOR=3 -DCONS_MAJOR=17 -DHZ=100 -DCPU_KHZ=200000 -DBUFPAGES=18 -DNBUF=18 -DNMBCLUSTERS=16 -DNKMEMCLUSTERS=32 -DDEBUG -DDIAGNOSTIC -DDEVPAGER -DVNODEPAGER -DSWAPPAGER -DTIMEZONE=480 -DDST=1 -DMAXUSERS=2 -o genassym ../../mips/pic32/genassym.c
/usr/bin/ld: cannot find crt1.o: No such file or directory
/usr/bin/ld: cannot find crti.o: No such file or directory

Do you have gcc installed at a proper place?
Code:
$ ls -l $MIPS_GCC_ROOT/bin/mips-sde-elf-gcc
-rwxr-xr-x 2 sergev sweng 686224 May  9  2014 /usr/local/mips-2014.05/bin/mips-sde-elf-gcc


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 9:30 pm 
User avatar

Joined: Mon Nov 12, 2012 3:17 pm
Posts: 164
Location: Bratislava, Slovakia
It looks like it is at proper place
Code:
jarin@plechac:~/LiteBSD$ ls -l $MIPS_GCC_ROOT/bin/mips-sde-elf-gcc
-rwxr-xr-x 2 root root 686224 máj  9  2014 /usr/local/mips-2014.05/bin/mips-sde-elf-gcc

_________________
http://jaromir.xf.cz/
https://hackaday.io/jaromir/


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 10:04 pm 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
Then bmake should use a proper prefix for gcc. See:
Code:
.if exists(${MIPS_GCC_ROOT}/bin/mips-sde-elf-gcc)
GCC_PREFIX      ?= ${MIPS_GCC_ROOT}/bin/mips-sde-elf-
.endif
in file LiteBSD/share/mk-pic32/sys.mk.


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 10:28 pm 
User avatar

Joined: Mon Nov 12, 2012 3:17 pm
Posts: 164
Location: Bratislava, Slovakia
I'm slightly confused.

My system is able to find the mips gcc binary, as I wrote before
Code:
jarin@plechac:~/LiteBSD$ ls -l $MIPS_GCC_ROOT/bin/mips-sde-elf-gcc
-rwxr-xr-x 2 root root 686224 máj  9  2014 /usr/local/mips-2014.05/bin/mips-sde-elf-gcc

The particular part in sys.mk looks like this, as expected
Code:
.if exists(${MIPS_GCC_ROOT}/bin/mips-sde-elf-gcc)
GCC_PREFIX      ?= ${MIPS_GCC_ROOT}/bin/mips-sde-elf-
.endif

So the bmake should be able to assign proper GCC_PREFIX, but probably I'm doing something wrong.

_________________
http://jaromir.xf.cz/
https://hackaday.io/jaromir/


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 10:35 pm 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
Oh well, I see what's wrong. At this point it tries to build a local binary for genassym, but in 32-bit mode. Seems like you are using 64-bit Linux, but no 32-bit libraries installed. Please, use:
Code:
sudo apt-get install libc6-i386


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 10:43 pm 
User avatar

Joined: Mon Nov 12, 2012 3:17 pm
Posts: 164
Location: Bratislava, Slovakia
Serge, thank you for your help so far.
Yes, I'm running it on 64-bit Linux, namely Ubuntu 14.04. I should specify it sooner, sorry for confusion.

I ran
Code:
sudo apt-get install libc6-i386

but it is already installed
Code:
jarin@plechac:~/LiteBSD$ sudo apt-get install libc6-i386
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libc6-i386 is already the newest version.
libc6-i386 set to manually installed.
                      ...
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.

The compilation result of LiteBSD kernel is unchanged too.

_________________
http://jaromir.xf.cz/
https://hackaday.io/jaromir/


Top
 Profile  
 
PostPosted: Fri Feb 20, 2015 11:04 pm 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
Just remove the -m32 from the LOCALCC variable in Makefile.pic32. I don't know why it's even in there - it's not wanted.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 12:15 am 
User avatar

Joined: Mon Nov 12, 2012 3:17 pm
Posts: 164
Location: Bratislava, Slovakia
Majenko: touche!
Code:
   text      data       bss       dec       hex   filename
 508472     13940     22372    544784     85010   vmunix.elf

Thank you guys for your help.

Now I'm building the unix and it runs for a few minutes looking OK, but it ends with
Code:
===> timedc
install -d /home/jarin/LiteBSD/DESTDIR/usr/sbin
install  -m 4555   timedc /home/jarin/LiteBSD/DESTDIR/usr/sbin/timedc
install -d /home/jarin/LiteBSD/DESTDIR/usr/share/man/cat8
install -c timedc.0 /home/jarin/LiteBSD/DESTDIR/usr/share/man/cat8
bmake -Cshare/man makedb
find /home/jarin/LiteBSD/DESTDIR/usr/share/man -type f -name '*.0' -print |  while read file;  do  sed -n -f /home/jarin/LiteBSD/DESTDIR/usr/share/man/makewhatis.sed $file;  done | col -b | sort -u > /tmp/whatis.db
sed: file /home/jarin/LiteBSD/DESTDIR/usr/share/man/makewhatis.sed line 61: Invalid range end
sed: file /home/jarin/LiteBSD/DESTDIR/usr/share/man/makewhatis.sed line 61: Invalid range end
sed: file /home/jarin/LiteBSD/DESTDIR/usr/share/man/makewhatis.sed line 61: Invalid range end
              ..........more than one thousand times the same line.................
sed: file /home/jarin/LiteBSD/DESTDIR/usr/share/man/makewhatis.sed line 61: Invalid range end
sed: file /home/jarin/LiteBSD/DESTDIR/usr/share/man/makewhatis.sed line 61: Invalid range end
install -m 444 /tmp/whatis.db /home/jarin/LiteBSD/DESTDIR/usr/share/man
jarin@plechac:~/LiteBSD$

Is this again issue with my 64-bit system?

_________________
http://jaromir.xf.cz/
https://hackaday.io/jaromir/


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 12:27 am 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
I think those are normal errors and can be ignored. It looks like it has all completed fine.

Now you need to "bmake fs" to see if it makes the filesystem image.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 12:30 am 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
It did not work for me without -m32 option... Well, probably I've fixed this already. Need to double check.

All these "sed: ... Invalid range end" messages are OK: just ignore them. It's a known issue in makewhatis.sed script. It results in /usr/bin/apropos not working properly - not so critical for now.


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 2:23 am 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
majenko wrote:
Just remove the -m32 from the LOCALCC variable in Makefile.pic32. I don't know why it's even in there - it's not wanted.

No, it will not works this way. Without -m32 option, genassym will generate incorrect values to assym.h files, and the kernel will crash with message:
Code:
panic: setrunqueue
syncing disks... done

dumping to dev 2, offset 64512
dump device bad

To fix linking issues for -m32 option, please install gcc-multilib:
Code:
sudo apt-get install gcc-multilib


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 8:25 am 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
Oh ok. That may be what i was seeing on my SDZL board. Rather than forcing the use of -m32 it would be better to fix genassym so it compiles and works properly on a 64 bit operating system.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 8:52 am 
Contributor
User avatar

Joined: Thu Nov 08, 2012 7:04 am
Posts: 2401
Location: Rapa Nui
@Jaromir: I started with 64bit linux, after exactly the same offline discussion with S&M I finally reinstalled ubuntu to 32bit and then it works according to the guide.. Welcome to the jungle again :)

PS: Updated the guide for 32 and 64bit linux versions.

_________________
Pukao Hats Cleaning Services Ltd.


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 8:54 am 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
majenko wrote:
Rather than forcing the use of -m32 it would be better to fix genassym so it compiles and works properly on a 64 bit operating system.

But it cannot... Genassym needs to be compiled on architecture with the same type sizes and alignments as the target system. It calculates and prints offsets of some kernel data structures. Fortunately, i386 and mips32 are compatible.


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 8:56 am 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
Hum... Sounds a bit short sighted of them... I'm sure there's a way it can work out those kind of things from the target not the host. I'll see if I can find time to dig into how it works.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 9:04 am 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
majenko wrote:
Hum... Sounds a bit short sighted of them... I'm sure there's a way it can work out those kind of things from the target not the host. I'll see if I can find time to dig into how it works.

Genassym ("generate assembler symbols") outputs defines for use by assembler routines. An alternative way would be to maintain these defines manually, and verify their correctness in some C routine at kernel startup.


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 9:06 am 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
I don't like the idea of doing things manually. I'd much rather spend two days writing scripts and things to generate a file that would take a few hours to create manually. It's more fun. :)

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Sat Feb 21, 2015 9:08 am 
User avatar

Joined: Mon Nov 12, 2012 3:17 pm
Posts: 164
Location: Bratislava, Slovakia
I followed Serge's advice of installing gcc-multilib on my 64-bit system and it seems to do the job even with -m32 option.
I ignored the sed messages and subsequently made the fs image. Everything seems OK, now I have binary for PIC and image for SD card. Thank you guys.

So, build steps seems to work, I'm going to find some appropriate hardware in my drawer to test it out.

_________________
http://jaromir.xf.cz/
https://hackaday.io/jaromir/


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 79 posts ]  Go to page 1, 2, 3, 4  Next

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron




Powered by phpBB® Forum Software © phpBB Group

BSD Daemon used with permission