A gamebuino "emulator" ?

Libraries, utilities, bootloaders...

Re: A gamebuino "emulator" ?

Postby AntonyPrince » Tue Aug 12, 2014 2:51 am

Skyrunner65 wrote:I can't make this in Fedora 20. I have all the dependencies except for Glut (I have freeglut).
And just to make sure, I did it in both the gbsim-master/ and gbsim-master/gbsim directories.
What did I do wrong?


I had the same problem. You're missing one of the following (I forget which one I was missing that caused the problem.):

gcc-avr (or avr-gcc)
gcc
avr-libc


The "cc: command not found" error is because make can't find the particular gcc compiler it is looking for. cc is the fallback for gcc and cc doesn't exist either, hence the error. It's probably that you're missing gcc-avr or gcc. I could be mistaken though. Only reason I mentioned avr-libc was because I originally tried compiling on CentOS which is RHEL based as well and I had particular problems finding libsdl2-dev and avr-libc.
User avatar
AntonyPrince
 
Posts: 21
Joined: Thu Aug 07, 2014 1:07 am
Location: Virginia, United States

Re: A gamebuino "emulator" ?

Postby Skyrunner65 » Tue Aug 12, 2014 11:45 pm

Thank you, but it gave me something else:

Code: Select all
[iobst@teens ~]$ cd /home/iobst/Downloads/gbsim-master
[iobst@teens gbsim-master]$ make
make -C simavr RELEASE=0
/usr/bin/bash: git: command not found
make[1]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
CONF obj-i686-redhat-linux/cores.deps
WARNING cores/sim_mega324.c did not compile, check your avr-gcc toolchain
make[1]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
/usr/bin/bash: git: command not found
make[1]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
make obj config
/usr/bin/bash: git: command not found
make[2]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
make[2]: Nothing to be done for `obj'.
CONF sim_core_decl.h
make[2]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
make libsimavr run_avr
/usr/bin/bash: git: command not found
make[2]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
CC sim/sim_interrupts.c
CC sim/sim_gdb.c
CC sim/sim_cycle_timers.c
CC sim/sim_core.c
sim/sim_elf.c:32:20: fatal error: libelf.h: No such file or directory
 #include <libelf.h>
                    ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/sim_elf.o] Error 1
make[2]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
make: *** [build-simavr] Error 2


Apparently it doesn't know what the command "git" is.
User avatar
Skyrunner65
 
Posts: 371
Joined: Thu Mar 20, 2014 5:37 pm
Location: NC,USA

Re: A gamebuino "emulator" ?

Postby 94k » Wed Aug 13, 2014 1:03 am

Try
Code: Select all
which git

in case it isn't installed you'll have to use your package manager to install it (git is extremely common, so you shouldn't run into problems there). If it is installed you might want to adjust your PATH.
User avatar
94k
 
Posts: 44
Joined: Sun Jul 27, 2014 9:41 pm
Location: Germany

Re: A gamebuino "emulator" ?

Postby Skyrunner65 » Wed Aug 13, 2014 3:32 am

Now it did this:
Code: Select all
[iobst@teens ~]$ cd /home/iobst/Downloads/gbsim-master
[iobst@teens gbsim-master]$ make
make -C simavr RELEASE=0
fatal: Not a git repository (or any parent up to mount point /home)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
make[1]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
make obj config
fatal: Not a git repository (or any parent up to mount point /home)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
make[2]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
make[2]: Nothing to be done for `obj'.
make[2]: Nothing to be done for `config'.
make[2]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
make libsimavr run_avr
fatal: Not a git repository (or any parent up to mount point /home)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
make[2]: Entering directory `/home/iobst/Downloads/gbsim-master/simavr'
sim/sim_elf.c:32:20: fatal error: libelf.h: No such file or directory
 #include <libelf.h>
                    ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/sim_elf.o] Error 1
make[2]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/iobst/Downloads/gbsim-master/simavr'
make: *** [build-simavr] Error 2
User avatar
Skyrunner65
 
Posts: 371
Joined: Thu Mar 20, 2014 5:37 pm
Location: NC,USA

Re: A gamebuino "emulator" ?

Postby 94k » Wed Aug 13, 2014 1:47 pm

You'll have to download the repository via git, try the following commands:
Code: Select all
git clone https://github.com/33d/gbsim.git
cd gbsim
make

You may have to install additional dependencies (I needed libelf and SDL2 (try to install the packages with "devel" suffix))
User avatar
94k
 
Posts: 44
Joined: Sun Jul 27, 2014 9:41 pm
Location: Germany

Re: A gamebuino "emulator" ?

Postby Skyrunner65 » Wed Aug 13, 2014 2:55 pm

Everything went well, until "glut.h" was not found as a file or directory.
I did get the devel version of libelf, and that got rid of some problems.
Code: Select all
[iobst@teens gbsim]$ make
make -C simavr RELEASE=0
make[1]: Entering directory `/home/iobst/gbsim/simavr'
make obj config
make[2]: Entering directory `/home/iobst/gbsim/simavr'
make[2]: Nothing to be done for `obj'.
make[2]: Nothing to be done for `config'.
make[2]: Leaving directory `/home/iobst/gbsim/simavr'
make libsimavr run_avr
make[2]: Entering directory `/home/iobst/gbsim/simavr'
CC sim/sim_elf.c
CC sim/sim_irq.c
CC sim/sim_vcd_file.c
CC sim/sim_io.c
CC sim/sim_avr.c
CC sim/sim_hex.c
CC sim/avr_adc.c
CC sim/avr_flash.c
CC sim/avr_lin.c
CC sim/avr_twi.c
CC sim/avr_uart.c
CC sim/avr_spi.c
CC sim/avr_usb.c
CC sim/avr_ioport.c
CC sim/avr_extint.c
CC sim/avr_eeprom.c
CC sim/avr_timer.c
CC sim/avr_bitbang.c
CC sim/avr_watchdog.c
CORE cores/sim_90usb162.c
CORE cores/sim_mega1280.c
CORE cores/sim_mega1281.c
CORE cores/sim_mega1284.c
CORE cores/sim_mega128.c
CORE cores/sim_mega128rfa1.c
CORE cores/sim_mega164.c
CORE cores/sim_mega168.c
CORE cores/sim_mega169.c
CORE cores/sim_mega16.c
CORE cores/sim_mega16m1.c
CORE cores/sim_mega2560.c
CORE cores/sim_mega328.c
CORE cores/sim_mega32.c
CORE cores/sim_mega48.c
CORE cores/sim_mega644.c
CORE cores/sim_mega88.c
CORE cores/sim_mega8.c
CORE cores/sim_megax4.c
CORE cores/sim_megax8.c
CORE cores/sim_megax.c
CORE cores/sim_megaxm1.c
CORE cores/sim_tiny13.c
CORE cores/sim_tiny2313.c
CORE cores/sim_tiny24.c
CORE cores/sim_tiny25.c
CORE cores/sim_tiny44.c
CORE cores/sim_tiny45.c
CORE cores/sim_tiny84.c
CORE cores/sim_tiny85.c
CORE cores/sim_tinyx4.c
CORE cores/sim_tinyx5.c
AR obj-i686-redhat-linux/libsimavr.a
SHARED obj-i686-redhat-linux/libsimavr.so.1
ln -sf libsimavr.so.1 obj-i686-redhat-linux/libsimavr.so
CC sim/run_avr.c
LD obj-i686-redhat-linux/run_avr.elf
ln -sf obj-i686-redhat-linux/run_avr.elf run_avr
make[2]: Leaving directory `/home/iobst/gbsim/simavr'
make[1]: Leaving directory `/home/iobst/gbsim/simavr'
make -C tests RELEASE=0
make[1]: Entering directory `/home/iobst/gbsim/tests'
AVR-CC atmega48_disabled_timer.c
    171         0         0       171        ab   atmega48_disabled_timer.axf
AVR-CC atmega88_coroutine.c
    703        36       159       898       382   atmega88_coroutine.axf
AVR-CC atmega644_adc_test.c
   2038       160        22      2220       8ac   atmega644_adc_test.axf
AVR-CC atmega88_uart_echo.c
   1872        68        88      2028       7ec   atmega88_uart_echo.axf
AVR-CC atmega48_watchdog_test.c
    371        82         6       459       1cb   atmega48_watchdog_test.axf
AVR-CC atmega88_timer16.c
    334         0         2       336       150   atmega88_timer16.axf
AVR-CC atmega48_enabled_timer.c
    177         0         0       177        b1   atmega48_enabled_timer.axf
AVR-CC attiny85_crash_gdb.c
     97         0         0        97        61   attiny85_crash_gdb.axf
AVR-CC atmega88_example.c
   1746       118         6      1870       74e   atmega88_example.axf
TST obj-i686-redhat-linux/test_atmega644_adc_test.tst
TST obj-i686-redhat-linux/test_atmega88_uart_echo.tst
TST obj-i686-redhat-linux/test_atmega48_watchdog_test.tst
TST obj-i686-redhat-linux/test_atmega88_timer16.tst
TST obj-i686-redhat-linux/test_atmega48_enabled_timer.tst
TST obj-i686-redhat-linux/test_atmega88_example.tst
TST obj-i686-redhat-linux/test_atmega48_disabled_timer.tst
make[1]: Leaving directory `/home/iobst/gbsim/tests'
make -C examples RELEASE=0
make[1]: Entering directory `/home/iobst/gbsim/examples'
for bi in board_timer_64led board_hd77480 board_simduino board_i2ctest board_ledramp; do make -C $bi; done
make[2]: Entering directory `/home/iobst/gbsim/examples/board_timer_64led'
AVR-CC atmega168_timer_64led.c
   1860        20        53      1933       78d   atmega168_timer_64led.axf
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/button.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/hc595.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
timer_64led.c:28:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/timer_64led.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_timer_64led'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_hd77480'
AVR-CC atmega48_charlcd.c
   2073        14         5      2092       82c   atmega48_charlcd.axf
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/ac_input.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/hd44780.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
../parts/hd44780_glut.c:28:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/hd44780_glut.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_hd77480'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_simduino'
AVR-CC atmega328p_dummy_blinky.c
    333        66         6       405       195   atmega328p_dummy_blinky.axf
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/button.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/uart_pty.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
simduino.c:33:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/simduino.o] Error 1
rm atmega328p_dummy_blinky.axf
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_simduino'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_i2ctest'
AVR-CC atmega1280_i2ctest.c
    941        16        12       969       3c9   atmega1280_i2ctest.axf
CC i2ctest.c
CC ../../examples/parts/i2c_eeprom.c
LD obj-i686-redhat-linux/i2ctest.elf
i2ctest done
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_i2ctest'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_ledramp'
AVR-CC atmega48_ledramp.c
   1839        32        11      1882       75a   atmega48_ledramp.axf
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
CC ../parts/button.c
Package glu was not found in the pkg-config search path.
Perhaps you should add the directory containing `glu.pc'
to the PKG_CONFIG_PATH environment variable
No package 'glu' found
ledramp.c:28:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/ledramp.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_ledramp'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/iobst/gbsim/examples'
make: *** [build-examples] Error 2
User avatar
Skyrunner65
 
Posts: 371
Joined: Thu Mar 20, 2014 5:37 pm
Location: NC,USA

Re: A gamebuino "emulator" ?

Postby 94k » Wed Aug 13, 2014 3:12 pm

Seems like you're missing libglu, try the devel version again.
User avatar
94k
 
Posts: 44
Joined: Sun Jul 27, 2014 9:41 pm
Location: Germany

Re: A gamebuino "emulator" ?

Postby Skyrunner65 » Wed Aug 13, 2014 3:31 pm

This is very annoying to me and you, I know, but:
Code: Select all
[iobst@teens gbsim]$ make
make -C simavr RELEASE=0
make[1]: Entering directory `/home/iobst/gbsim/simavr'
make obj config
make[2]: Entering directory `/home/iobst/gbsim/simavr'
make[2]: Nothing to be done for `obj'.
make[2]: Nothing to be done for `config'.
make[2]: Leaving directory `/home/iobst/gbsim/simavr'
make libsimavr run_avr
make[2]: Entering directory `/home/iobst/gbsim/simavr'
make[2]: Nothing to be done for `libsimavr'.
make[2]: `run_avr' is up to date.
make[2]: Leaving directory `/home/iobst/gbsim/simavr'
make[1]: Leaving directory `/home/iobst/gbsim/simavr'
make -C tests RELEASE=0
make[1]: Entering directory `/home/iobst/gbsim/tests'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/iobst/gbsim/tests'
make -C examples RELEASE=0
make[1]: Entering directory `/home/iobst/gbsim/examples'
for bi in board_timer_64led board_hd77480 board_simduino board_i2ctest board_ledramp; do make -C $bi; done
make[2]: Entering directory `/home/iobst/gbsim/examples/board_timer_64led'
timer_64led.c:28:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/timer_64led.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_timer_64led'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_hd77480'
../parts/hd44780_glut.c:28:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/hd44780_glut.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_hd77480'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_simduino'
simduino.c:33:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/simduino.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_simduino'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_i2ctest'
i2ctest done
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_i2ctest'
make[2]: Entering directory `/home/iobst/gbsim/examples/board_ledramp'
ledramp.c:28:21: fatal error: GL/glut.h: No such file or directory
 #include <GL/glut.h>
                     ^
compilation terminated.
make[2]: *** [obj-i686-redhat-linux/ledramp.o] Error 1
make[2]: Leaving directory `/home/iobst/gbsim/examples/board_ledramp'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/iobst/gbsim/examples'
make: *** [build-examples] Error 2
User avatar
Skyrunner65
 
Posts: 371
Joined: Thu Mar 20, 2014 5:37 pm
Location: NC,USA

Re: A gamebuino "emulator" ?

Postby 94k » Wed Aug 13, 2014 4:03 pm

It's still missing glu, I don't know which package exactly, since it worked for me without installing any additional glu package (meybe it was already installed though). Try your package manager and find something like glulib-devel.
User avatar
94k
 
Posts: 44
Joined: Sun Jul 27, 2014 9:41 pm
Location: Germany

Re: A gamebuino "emulator" ?

Postby Skyrunner65 » Wed Aug 13, 2014 6:05 pm

Now that I have it working, I think that we should put the emulator on the wiki.
I'll put instructions on how to run it on linux.
But to clean up the folder, what is needed to run the emulator?
User avatar
Skyrunner65
 
Posts: 371
Joined: Thu Mar 20, 2014 5:37 pm
Location: NC,USA

PreviousNext

Return to Software Development

Who is online

Users browsing this forum: No registered users and 1 guest

cron