GithubHelp home page GithubHelp logo

carun / gba_dlang Goto Github PK

View Code? Open in Web Editor NEW

This project forked from bmchtech/gba_dlang

0.0 0.0 0.0 439 KB

gba runtime and libraries for dlang

Home Page: https://beanmachine.alt.icu/post/d_on_gba/

D 100.00%

gba_dlang's Introduction

gba_dlang

dlang libraries and runtime for the Game Boy Advance handheld game console.

about

yes, you read that right! this is a dlang library and runtime for the gameboy advance.

acknowledgements

this would not have been possible without:

what's included

  • minimal druntime
  • minimal core.stdc, std, rt, object.d
  • libtonc bindings
  • utilities for mmio and volatile bare metal io

demo

see the demo project for a fully functional example of building a gba rom with dlang.

cd demo
make clean
make build
mgba-qt GBADlang.gba

troubleshooting

errors about __aeabi_read_tp

this is about trying to read thread-local storage (TLS) for global variables. on a bare metal system like the GBA it's easier to just not worry about TLS and just go with thread-global storage.

if you get these errors, make sure you prefix your global variables with __gshared. this enables default C-style behavior of thread global storage.

errors about TLS reference ... mismatches non-TLS definition ... section .bss

this means you're using a non-TLS variable with a TLS reference. this can often happen if you're individually compiling objects and then linking after you change the thread storage type of your variable. the solution is to just clean all intermediate object files and rebuild.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.