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

make : deprecate #10514

Merged
merged 11 commits into from
Dec 2, 2024
Merged

make : deprecate #10514

merged 11 commits into from
Dec 2, 2024

Conversation

ggerganov
Copy link
Owner

ref #10268

Disabling the Makefile unless LLAMA_MAKEFILE is defined. This should give more focus for the CMake build and will help clean-up any usage of make in the existing CI. The Makefile will be eventually removed or stripped to a very minimal version.

@MaggotHATE
Copy link
Contributor

stripped to a very minimal version

That would be a much more preferred option. Like LostRuins mentioned in the original discussion, Makefile is a very simple and handy option that gives additional flexibility to projects that use llama.cpp, and it is multiplatform.

If you see the current state of Makefile as a burden, it is worth at least leaving a simplified version - for example, main and server as the most popular applications. This would serve not only as a quick "build and test" option, but also as an example for those who use Makefile in their projects. Then, for all advanced options users can be directed towards CMake only.

@slaren
Copy link
Collaborator

slaren commented Nov 26, 2024

Is there a single platform that does not have easy access to cmake? If typing two commands instead of one is too much effort, we can always have the Makefile run cmake. In any case, let's keep that discussion to #10268.

@github-actions github-actions bot added devops improvements to build systems and github actions documentation Improvements or additions to documentation labels Nov 28, 2024
@ggerganov ggerganov marked this pull request as ready for review December 2, 2024 08:27
@ggerganov
Copy link
Owner Author

Need to fix the scripts/compare* to use CMake builds instead of the Makefile and we can merge. The Swift build can be fixed later in #10525.

@ggerganov ggerganov requested a review from slaren December 2, 2024 08:28
@slaren slaren force-pushed the gg/make-deprecate branch from 3c29b91 to bbff53a Compare December 2, 2024 17:09
@max-krasnyansky
Copy link
Collaborator

Very nice!
Good to see mostly deletions in the changes :)

Makefile Outdated Show resolved Hide resolved
Co-authored-by: Diego Devesa <[email protected]>
@ggerganov ggerganov merged commit 8648c52 into master Dec 2, 2024
44 checks passed
@ggerganov ggerganov deleted the gg/make-deprecate branch December 2, 2024 19:22
@jboero
Copy link
Contributor

jboero commented Dec 4, 2024

This breaks the SRPM specs again. Does anybody who uses the RPM specs have a preference for cmake+libs vs make+static builds? The rate things change in cmake I'm tempted to just stick with static Makefile builds, rather than mess with rpath issues, shared objects, and extra binaries.

@slaren
Copy link
Collaborator

slaren commented Dec 4, 2024

If you want a static build just disable BUILD_SHARED_LIBS. Do not use make, it will be removed completely in the future.

I am not sure how people are using the RPMs, but if the goal is to distribute binaries, then you should use shared libraries, GGML_BACKEND_DL and GGML_CPU_ALL_VARIANTS to ensure best compatibility and performance.

ngxson added a commit to huggingface/huggingface.js that referenced this pull request Dec 4, 2024
Ref: ggerganov/llama.cpp#10514

The recommended way to build llama.cpp is by using `cmake` command.
jboero added a commit to jboero/llama.cpp that referenced this pull request Dec 4, 2024
Makefile is being deprecated. Stick with static builds using cmake and skip rpaths checks.

ggerganov#10514
@jboero jboero mentioned this pull request Dec 4, 2024
@jboero
Copy link
Contributor

jboero commented Dec 4, 2024

#10663

Unfortunately packaging RPMs isn't quite so simple. Every time a build change refactors out a different library or file the rpm inventory needs to be updated to list which files it includes. This was breaking quite a bit of my COPR build automation as updates arrived so I stuck with static builds.

I suppose the proper way to do this would be refactor out separate RPMs for just libs and server binaries, etc.

tinglou pushed a commit to tinglou/llama.cpp that referenced this pull request Dec 7, 2024
* make : deprecate

ggml-ci

* ci : disable Makefile builds

ggml-ci

* docs : remove make references [no ci]

* ci : disable swift build

ggml-ci

* docs : remove obsolete make references, scripts, examples

ggml-ci

* basic fix for compare-commits.sh

* update build.md

* more build.md updates

* more build.md updates

* more build.md updates

* Update Makefile

Co-authored-by: Diego Devesa <[email protected]>

---------

Co-authored-by: slaren <[email protected]>
arthw pushed a commit to arthw/llama.cpp that referenced this pull request Dec 20, 2024
* make : deprecate

ggml-ci

* ci : disable Makefile builds

ggml-ci

* docs : remove make references [no ci]

* ci : disable swift build

ggml-ci

* docs : remove obsolete make references, scripts, examples

ggml-ci

* basic fix for compare-commits.sh

* update build.md

* more build.md updates

* more build.md updates

* more build.md updates

* Update Makefile

Co-authored-by: Diego Devesa <[email protected]>

---------

Co-authored-by: slaren <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
devops improvements to build systems and github actions documentation Improvements or additions to documentation examples script Script related server
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants