Skip to content

Provide TARGET and TARGET_CFLAGS for 64-bit RISC-V and 32-bit Arm#5

Open
ptesarik wants to merge 3 commits intofujitsu:masterfrom
ptesarik:master
Open

Provide TARGET and TARGET_CFLAGS for 64-bit RISC-V and 32-bit Arm#5
ptesarik wants to merge 3 commits intofujitsu:masterfrom
ptesarik:master

Conversation

@ptesarik
Copy link

Fix build for riscv64 and arm* target architectures.

d-hatayama and others added 3 commits May 29, 2025 10:32
Currently, there is build failure on aarch64 and ppc64le as follows:

    gcc -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64 -mcpu=power8 -mtune=power8 -fasynchronous-unwind-tables -fstack-clash-protection -Wall -I/usr/include/crash -nostartfiles -shared -rdynamic -o trace.so trace.c -fPIC -D
    gcc: error: macro name missing after '-D'

The failure is caused by missing arguments for -D option because
TARGET variable is empty.

This commit fixes the issue by defining TARGET variable properly
according to aarch64 and ppc64le.

Signed-off-by: HATAYAMA Daisuke <d.hatayama@fujitsu.com>
Set TARGET and TARGET_CFLAGS for 32-bit Arm variants.

Signed-off-by: Petr Tesarik <ptesarik@suse.com>
Set TARGET and TARGET_CFLAGS for riscv64.

Signed-off-by: Petr Tesarik <ptesarik@suse.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants