Skip to content

Commit

Permalink
build: remove target-cpu from rustflags #16
Browse files Browse the repository at this point in the history
  • Loading branch information
Itsusinn committed Sep 11, 2024
1 parent 8eb0efa commit 5e727dd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 12 deletions.
9 changes: 1 addition & 8 deletions .github/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,6 @@ COPY . /app/tuic

WORKDIR /app/tuic

RUN if [ "$DOCKER_PLATFORM" = "amd64" ]; then \
echo "Setting RUSTFLAGS for x86_64" && \
export RUSTFLAGS="-Ctarget-cpu=sandybridge" ; \
else \
export RUSTFLAGS="" ; \
fi

RUN cargo build --release --config net.git-fetch-with-cli=true --package tuic-server
RUN cp ./target/release/tuic-server /usr/bin/tuic-server
RUN chmod +x /usr/bin/tuic-server
Expand All @@ -25,4 +18,4 @@ FROM alpine:latest as main
COPY --from=build /usr/bin/tuic-server /usr/bin/tuic-server

ENTRYPOINT [ "/usr/bin/tuic-server" ]
CMD [ "-c", "/etc/tuic/config.json" ]
CMD [ "-c", "/etc/tuic/config.json" ]
4 changes: 0 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ jobs:
target: x86_64-unknown-linux-gnu
release-name: x86_64-linux
cross: true
rustflags: "-Ctarget-cpu=sandybridge"
- os: ubuntu-latest
target: i686-unknown-linux-gnu
release-name: i686-linux
Expand All @@ -51,7 +50,6 @@ jobs:
target: x86_64-unknown-linux-musl
release-name: x86_64-linux-musl
cross: true
rustflags: "-Ctarget-cpu=sandybridge"
- os: ubuntu-latest
target: i686-unknown-linux-musl
release-name: i686-linux-musl
Expand Down Expand Up @@ -88,7 +86,6 @@ jobs:
release-name: x86_64-windows
cross: false
postfix: ".exe"
rustflags: "-Ctarget-cpu=sandybridge"
- os: windows-latest
target: i686-pc-windows-msvc
release-name: i686-windows
Expand All @@ -100,7 +97,6 @@ jobs:
target: x86_64-apple-darwin
release-name: x86_64-darwin
cross: false
rustflags: "-Ctarget-cpu=sandybridge"
- os: macos-14
target: aarch64-apple-darwin
release-name: aarch64-darwin
Expand Down

0 comments on commit 5e727dd

Please sign in to comment.