+
Skip to content

Following the manual steps to build a ROM causes the first Makefile to not work #129

Open
@exelotl

Description

@exelotl

If you follow the manual steps:

cd libtonc-examples/basic/first/source

# Compile first.c to first.o
arm-none-eabi-gcc -mthumb -c first.c

# Link first.o (and standard libs) to first.elf
arm-none-eabi-gcc -specs=gba.specs -mthumb first.o -o first.elf

# Strip to binary-only
arm-none-eabi-objcopy -O binary first.elf first.gba

# Fix header
gbafix first.gba

Then the first project won't build via make anymore:

$ make
linking cartridge
/opt/devkitpro/devkitARM/bin/../lib/gcc/arm-none-eabi/13.1.0/../../../
../arm-none-eabi/bin/ld: cannot find first.o: No such file or directory

The presence of a .o file in the source directory seems to mess things up... We should instead tell people to copy first.c into a new location.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载