Skip to content

Commit

Permalink
resource: move fontawesome to .rodata (#1259)
Browse files Browse the repository at this point in the history
  • Loading branch information
goeiecool9999 authored Jul 19, 2024
1 parent 9d36693 commit 7522c84
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/resource/embedded/fontawesome.S
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.section .text
.rodata
.global g_fontawesome_data, g_fontawesome_size

g_fontawesome_data:
Expand Down

2 comments on commit 7522c84

@Tatsh
Copy link

@Tatsh Tatsh commented on 7522c84 Jul 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This breaks building with GCC:

/var/tmp/portage/games-emulation/cemu-2.0_p20240719/work/Cemu-7522c8470ee27d50a68ba662ae721b69018f3a8f/src/resource/embedded/fontawesome.S: Assembler messages:
/var/tmp/portage/games-emulation/cemu-2.0_p20240719/work/Cemu-7522c8470ee27d50a68ba662ae721b69018f3a8f/src/resource/embedded/fontawesome.S:1: Error: unknown pseudo-op: `.rodata'

@Tatsh
Copy link

@Tatsh Tatsh commented on 7522c84 Jul 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please consider making it like so. This will work in Clang and GCC.

.section .rodata,"",%progbits
.global g_fontawesome_data, g_fontawesome_size

g_fontawesome_data:
.incbin "fontawesome-webfont.ttf"
g_fontawesome_size:
.int g_fontawesome_size - g_fontawesome_data

.section .note.GNU-stack,"",%progbits

Please sign in to comment.