Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support clang #9

Merged
merged 8 commits into from
Sep 4, 2023
Merged

Support clang #9

merged 8 commits into from
Sep 4, 2023

Conversation

joii2020
Copy link
Collaborator

@joii2020 joii2020 commented Sep 1, 2023

Support clang by Makefile.clang

Makefile.clang Outdated
Comment on lines 1 to 9
# TARGET := riscv64-unknown-linux-gnu
# CC := $(TARGET)-gcc
# LD := $(TARGET)-gcc
# OBJCOPY := $(TARGET)-objcopy
# AR := $(TARGET)-ar
# RANLIB := $(TARGET)-ranlib
# GCC_CFLAGS := -nostartfiles -Wno-nonnull-compare -Wno-dangling-pointer -Wno-stringop-overflow
# LDFLAGS := -static -Wl,--gc-sections
# AUTH_DYN_LIST := -Wl,--dynamic-list c/auth.syms
Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove these.

# LDFLAGS := -static -Wl,--gc-sections
# AUTH_DYN_LIST := -Wl,--dynamic-list c/auth.syms

CC := clang-16
Copy link
Collaborator

Choose a reason for hiding this comment

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

Use ?= instead of :=. Give a chance to set CC from environment.

Makefile Outdated
@@ -3,6 +3,7 @@ CC := $(TARGET)-gcc
LD := $(TARGET)-gcc
Copy link
Collaborator

Choose a reason for hiding this comment

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

Don't update this file.

Makefile.clang Outdated
make -C deps/mbedtls/library clean
make -C deps/libecc clean

.PHONY: all all-via-docker
Copy link
Collaborator

Choose a reason for hiding this comment

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

all-via-docker is not used.

Comment on lines 1 to 10
# TARGET := riscv64-unknown-linux-gnu
# CC := $(TARGET)-gcc
# LD := $(TARGET)-gcc
# OBJCOPY := $(TARGET)-objcopy
# AR := $(TARGET)-ar
# RANLIB := $(TARGET)-ranlib
# GCC_CFLAGS := -nostartfiles \
# -Wno-nonnull-compare \
# -Wno-dangling-pointer \
# -Wno-stringop-overflow
Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove these.

@joii2020 joii2020 merged commit 934e138 into nervosnetwork:main Sep 4, 2023
2 checks passed
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