Skip to content

v1.7.3 breaks SwiftUI example app #2646

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

Open
ezanalemma opened this issue Dec 18, 2024 · 5 comments
Open

v1.7.3 breaks SwiftUI example app #2646

ezanalemma opened this issue Dec 18, 2024 · 5 comments

Comments

@ezanalemma
Copy link

Hi all,

It seems like somewhere between 1.7.2 & 1.7.3, the SwiftUI example app breaks because of: 'whisper.h' file not found with <angled> include; use "quotes" instead

Screenshot 2024-12-18 at 11 35 00 AM

Any ideas for fix?

Thanks! 🙏

@ggerganov
Copy link
Member

See #2616 (reply in thread) and reference therein.

@ezanalemma
Copy link
Author

Thanks @ggerganov. Finally got the project to build after running the cmake commands, but the app crashes on launch:

Library not loaded: @rpath/libggml.dylib

Will have to look into it later.

@itsthisjustin
Copy link

Thanks @ggerganov. Finally got the project to build after running the cmake commands, but the app crashes on launch:

Library not loaded: @rpath/libggml.dylib

Will have to look into it later.

Let me know if you get this working! We may have to roll back to an older version just to release an update to our app which sucks.

@bingcheng1998
Copy link

try this, it works for me:
ggml-org/llama.cpp#10747 (comment)

@bingcheng1998
Copy link

step1. build the lib:

mkdir build-spm-ios
cd build-spm-ios

 cmake -B build -G Xcode .. \
	    -DCMAKE_INSTALL_PREFIX=tmp \
            -DGGML_METAL_USE_BF16=ON \
            -DGGML_METAL_EMBED_LIBRARY=ON \
            -DWHISPER_BUILD_EXAMPLES=OFF \
            -DWHISPER_BUILD_TESTS=OFF \
            -DWHISPER_BUILD_SERVER=OFF \
            -DCMAKE_SYSTEM_NAME=iOS \
            -DCMAKE_OSX_DEPLOYMENT_TARGET=14.0 \
            -DCMAKE_XCODE_ATTRIBUTE_DEVELOPMENT_TEAM=ggml ..

cmake --build build --config Release -j $(sysctl -n hw.logicalcpu) -- CODE_SIGNING_ALLOWED=NO


sudo cmake --install build --config Release

step2. add frameworks to project

Image

step3. add search paths

Image

step4. add .bin model to the folder

Image

step5. build success

Image

have fun!

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

No branches or pull requests

4 participants