news 2026/8/22 13:41:39

幽冥大陆(七十五) MinGW编译 WISPER ASR源码fairyalliancewhisper——东方仙盟练气期

作者头像

张小明

前端开发工程师

1.2k 24
文章封面图
幽冥大陆(七十五) MinGW编译 WISPER ASR源码fairyalliancewhisper——东方仙盟练气期

1.下载源码

https://github.com/cyberwin/fairyalliancewhisper

2.下载编译工具

https://www.mingw-w64.org/

3.配置系统变量

4.编译

g++ examples/cli/cli.cpp whisper.cpp -o fairy_whisper_cli.exe -lws2_32 -lpthread -O3 -std=c++17
examples/cli/cli.cpp:1:10: fatal error: common.h: No such file or directory
1 | #include "common.h"
| ^~~~~~~~~~
compilation terminated.
cc1plus.exe: fatal error: whisper.cpp: No such file or directory
compilation terminated.

D:\ai\asr\fairyalliancewhisper>g++ examples/cli/cli.cpp examples/common.cpp whisper.cpp -o fairy_whisper_cli.exe -I examples/common -lws2_32 -lpthread -O3 -std=c++17
examples/cli/cli.cpp:1:10: fatal error: common.h: No such file or directory
1 | #include "common.h"
| ^~~~~~~~~~
compilation terminated.
cc1plus.exe: fatal error: whisper.cpp: No such file or directory
compilation terminated.

D:\ai\asr\fairyalliancewhisper>make build
cmake -B build
-- Building for: Visual Studio 17 2022
CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.10 will be removed from a future version of
CMake.

Update the VERSION argument <min> value. Or, use the <min>...<max> syntax
to tell CMake that the project requires at least <min> but has been updated
to work with policies introduced by <max> or earlier.


-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.17763.
-- The C compiler identification is MSVC 19.40.33811.0
-- The CXX compiler identification is MSVC 19.40.33811.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: D:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: D:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Could NOT find Git (missing: GIT_EXECUTABLE)
-- Could NOT find Git (missing: GIT_EXECUTABLE)
CMake Warning at cmake/build-info.cmake:14 (message):
Git not found. Build info will not be accurate.
Call Stack (most recent call first):
CMakeLists.txt:93 (include)


-- The ASM compiler identification is MSVC
-- Found assembler: D:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - not found
-- Found Threads: TRUE
-- Warning: ccache not found - consider installing it for faster compilation or disable this warning with GGML_CCACHE=OFF
-- CMAKE_SYSTEM_PROCESSOR: AMD64
-- CMAKE_GENERATOR_PLATFORM:
-- GGML_SYSTEM_ARCH: x86
-- Including CPU backend
-- Found OpenMP_C: -openmp (found version "2.0")
-- Found OpenMP_CXX: -openmp (found version "2.0")
-- Found OpenMP: TRUE (found version "2.0")
-- x86 detected
-- Performing Test HAS_AVX_1
-- Performing Test HAS_AVX_1 - Success
-- Performing Test HAS_AVX2_1
-- Performing Test HAS_AVX2_1 - Success
-- Performing Test HAS_FMA_1
-- Performing Test HAS_FMA_1 - Success
-- Performing Test HAS_AVX512_1
-- Performing Test HAS_AVX512_1 - Failed
-- Performing Test HAS_AVX512_2
-- Performing Test HAS_AVX512_2 - Failed
-- Adding CPU backend variant ggml-cpu: /arch:AVX2 GGML_AVX2;GGML_FMA;GGML_F16C
-- ggml version: 0.9.4
-- ggml commit: unknown
-- Configuring done (88.1s)
-- Generating done (1.5s)
-- Build files have been written to: D:/ai/asr/fairyalliancewhisper/build
cmake --build build --config Release
适用于 .NET Framework MSBuild 版本 17.10.4+10fbfbf2e

1>Checking Build System
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/deprecation-warning/CMakeLists.txt
deprecation-warning.cpp
bench.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\bench.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/ggml/src/CMakeLists.txt
ggml.c
ggml.cpp
ggml-alloc.c
ggml-quants.c
正在生成代码...
ggml-backend.cpp
ggml-opt.cpp
ggml-threading.cpp
gguf.cpp
正在生成代码...
正在创建库 D:/ai/asr/fairyalliancewhisper/build/ggml/src/Release/ggml-base.lib 和对象 D:/ai/asr/fairyalliancewhisper/build/
ggml/src/Release/ggml-base.exp
ggml-base.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\ggml-base.dll
Building Custom Rule D:/ai/asr/fairyalliancewhisper/ggml/src/CMakeLists.txt
ggml-cpu.c
ggml-cpu.cpp
repack.cpp
hbm.cpp
traits.cpp
amx.cpp
mmq.cpp
binary-ops.cpp
unary-ops.cpp
vec.cpp
ops.cpp
正在生成代码...
quants.c
quants.c
repack.cpp
正在创建库 D:/ai/asr/fairyalliancewhisper/build/ggml/src/Release/ggml-cpu.lib 和对象 D:/ai/asr/fairyalliancewhisper/build/g
gml/src/Release/ggml-cpu.exp
ggml-cpu.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\ggml-cpu.dll
Building Custom Rule D:/ai/asr/fairyalliancewhisper/ggml/src/CMakeLists.txt
ggml-backend-reg.cpp
正在创建库 D:/ai/asr/fairyalliancewhisper/build/ggml/src/Release/ggml.lib 和对象 D:/ai/asr/fairyalliancewhisper/build/ggml/
src/Release/ggml.exp
ggml.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\ggml.dll
Building Custom Rule D:/ai/asr/fairyalliancewhisper/src/CMakeLists.txt
whisper.cpp
Auto build dll exports
正在创建库 D:/ai/asr/fairyalliancewhisper/build/src/Release/whisper.lib 和对象 D:/ai/asr/fairyalliancewhisper/build/src/Rel
ease/whisper.exp
whisper.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\whisper.dll
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/CMakeLists.txt
common.cpp
common-ggml.cpp
common-whisper.cpp
grammar-parser.cpp
正在生成代码...
common.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\examples\Release\common.lib
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/deprecation-warning/CMakeLists.txt
deprecation-warning.cpp
main.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\main.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/quantize/CMakeLists.txt
quantize.cpp
quantize.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\quantize.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/tests/CMakeLists.txt
test-vad.cpp
D:\ai\asr\fairyalliancewhisper\tests\test-vad.cpp(74,64): warning C4267: “参数”: 从“size_t”转换到“int”,可能丢失数据 [D:\ai\asr\fair
yalliancewhisper\build\tests\test-vad.vcxproj]
test-vad.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\test-vad.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/tests/CMakeLists.txt
test-vad-full.cpp
D:\ai\asr\fairyalliancewhisper\tests\test-vad-full.cpp(40,5): warning C4267: “参数”: 从“size_t”转换到“int”,可能丢失数据 [D:\ai\asr\
fairyalliancewhisper\build\tests\test-vad-full.vcxproj]
test-vad-full.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\test-vad-full.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/vad-speech-segments/CMakeLists.txt
speech.cpp
vad-speech-segments.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\vad-speech-segments.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/bench/CMakeLists.txt
bench.cpp
whisper-bench.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\whisper-bench.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/cli/CMakeLists.txt
cli.cpp
whisper-cli.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\whisper-cli.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/examples/server/CMakeLists.txt
server.cpp
whisper-server.vcxproj -> D:\ai\asr\fairyalliancewhisper\build\bin\Release\whisper-server.exe
Building Custom Rule D:/ai/asr/fairyalliancewhisper/CMakeLists.txt

5.运行测试

阿雪技术观
在科技发展浪潮中,我们不妨积极投身技术共享。不满足于做受益者,更要主动担当贡献者。无论是分享代码、撰写技术博客,还是参与开源项目维护改进,每一个微小举动都可能蕴含推动技术进步的巨大能量。东方仙盟是汇聚力量的天地,我们携手在此探索硅基生命,为科技进步添砖加瓦。

Hey folks, in this wild tech - driven world, why not dive headfirst into the whole tech - sharing scene? Don't just be the one reaping all the benefits; step up and be a contributor too. Whether you're tossing out your code snippets, hammering out some tech blogs, or getting your hands dirty with maintaining and sprucing up open - source projects, every little thing you do might just end up being a massive force that pushes tech forward. And guess what? The Eastern FairyAlliance is this awesome place where we all come together. We're gonna team up and explore the whole silicon - based life thing, and in the process, we'll be fueling the growth of technology

版权声明: 本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若内容造成侵权/违法违规/事实不符,请联系邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
网站建设 2026/8/21 18:59:20

NVIDIA官方示例代码库:TensorRT应用参考

NVIDIA官方示例代码库&#xff1a;TensorRT应用参考 在当今AI系统部署的实际战场上&#xff0c;一个训练得再完美的模型&#xff0c;如果推理慢、耗资源、上不了线&#xff0c;终究只是实验室里的“艺术品”。尤其是在自动驾驶的毫秒级响应、视频监控的实时分析、推荐系统的高…

作者头像 李华
网站建设 2026/8/21 18:59:22

AI编程软件评测:2026年最值得关注的10款AI编程软件

在软件开发效率至上的今天&#xff0c;AI编程工具已从新奇概念转变为开发者的核心生产力伙伴。2025~2026年&#xff0c;市场格局进一步分化&#xff0c;工具的能力边界从简单的代码补全&#xff0c;扩展到理解复杂项目、自动执行开发任务乃至参与全流程协作。面对层出不穷的选择…

作者头像 李华
网站建设 2026/8/21 17:25:06

TensorRT在短视频内容审核中的应用实例

TensorRT在短视频内容审核中的应用实例 如今&#xff0c;一条短视频从上传到上线&#xff0c;往往只需要几秒钟。在这短暂的时间里&#xff0c;平台不仅要完成视频转码、封面抽取&#xff0c;还要完成一轮或多轮内容安全审核——判断是否包含涉黄、暴恐、违禁信息。对于日均处理…

作者头像 李华
网站建设 2026/8/21 18:59:24

使用TensorRT优化语义分割模型的实战记录

使用TensorRT优化语义分割模型的实战记录 在自动驾驶系统中&#xff0c;实时感知周围环境是决策的基础。一辆车每秒需要处理数十帧高分辨率图像&#xff0c;并对道路、行人、车辆等进行像素级识别——这正是语义分割的核心任务。然而&#xff0c;即便使用SOTA模型&#xff0c;…

作者头像 李华
网站建设 2026/8/21 18:59:19

如何使用 ONNX 运行 Stable Diffusion

原文&#xff1a;towardsdatascience.com/how-to-run-stable-diffusion-with-onnx-dafd2d29cd14?sourcecollection_archive---------4-----------------------#2024-05-13 解决安装过程中的兼容性问题 | ONNX 用于 NVIDIA GPU | Hugging Face 的 Optimum 库 https://medium.c…

作者头像 李华
网站建设 2026/8/21 18:59:20

NVIDIA官方镜像安全性认证说明:TensorRT篇

NVIDIA官方镜像安全性与TensorRT推理优化实践 在AI模型日益复杂、部署场景愈发多样的今天&#xff0c;如何让一个训练好的神经网络真正“跑得快、稳得住、安心得下”&#xff0c;是每个工程师都绕不开的问题。尤其是在金融、医疗、自动驾驶这类对延迟和可靠性要求极高的领域&a…

作者头像 李华