Conversation
|
It did not. However, when I commented out the |
|
I don't know if this helps, but this is how I build: FROM alpine:3.17.2 AS alpine0
RUN mkdir /whisper && \
wget -q https://github.com/masterful/whisper.cpp/tarball/master -O - | \
tar -xz -C /whisper --strip-components 1
# git alternative
# RUN apk add git &&
# git clone --depth 1 https://github.com/ggerganov/whisper.cpp.git /whisper
WORKDIR /whisper
RUN apk add --quiet g++ make bash wget sdl2-dev alsa-utils
# Workaround build
RUN cat > Makefile.musl <<MAKEFILE
CFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE
CXXFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE
MAKEFILE
RUN make -f Makefile -f Makefile.musl main stream command talk bench
# Once workaround is no longer necessary
# RUN make main stream command talk bench
RUN bash ./models/download-ggml-model.sh base.en
FROM alpine:3.17.2
COPY --from=alpine0 /whisper/main /usr/local/bin/whisper
COPY --from=alpine0 /whisper/stream /usr/local/bin/stream
COPY --from=alpine0 /whisper/talk /usr/local/bin/talk
COPY --from=alpine0 /whisper/command /usr/local/bin/wcommand
RUN mkdir /root/models
COPY --from=alpine0 /whisper/models/ggml-base.en.bin /root/models/ggml-base.en.bin
RUN apk add --quiet sdl2-dev alsa-utils
WORKDIR /root
# To use stream in a container (linux hosts only):
# docker build . -t whisper
# docker run -it --rm --device /dev/snd:/dev/snd whisper streamThen to extract binaries docker build -t whispercpp .
docker create --name whispercpp whispercpp
docker cp whispercpp:/usr/local/bin/whisper whisper
docker cp whispercpp:/usr/local/bin/stream wstream
docker cp whispercpp:/root/models/ggml-base.en.bin ggml-base.en.bin
docker rm whispercpp |
Member
Author
|
Directly adding |
I asked ChatGPT
ifneq ($(wildcard /usr/include/musl/*),)
CFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE
CXXFLAGS += -D_POSIX_SOURCE -D_GNU_SOURCE
endif
ifeq ($(shell ldd /bin/ls | grep -q musl && echo true),true)
endif
ifeq ($(shell pkg-config --exists musl && echo true),true)
endifI tested the first and it worked. |
Contributor
|
Currently, I have a job to build the binary for MUSL python wheel and seems like it fails as well. 🤔 |
Member
Author
|
Added the suggestion by ChatGPT |
anandijain
pushed a commit
to anandijain/whisper.cpp
that referenced
this pull request
Apr 28, 2023
jacobwu-b
pushed a commit
to jacobwu-b/Transcriptify-by-whisper.cpp
that referenced
this pull request
Oct 24, 2023
jacobwu-b
pushed a commit
to jacobwu-b/Transcriptify-by-whisper.cpp
that referenced
this pull request
Oct 24, 2023
landtanin
pushed a commit
to landtanin/whisper.cpp
that referenced
this pull request
Dec 16, 2023
iThalay
pushed a commit
to iThalay/whisper.cpp
that referenced
this pull request
Sep 23, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
close #37
@mikeslattery Could you please check if this works on MUSL Linux?