llama.cpp icon indicating copy to clipboard operation
llama.cpp copied to clipboard

`build`: generate hex dump of server assets during build

Open ochafik opened this issue 4 months ago • 11 comments

Currently one needs to manually regenerate asset files in examples/server, which:

  • is easy to forget
  • ~~may cause a security risk~~ (reviewers are unlikely to unescape the code - don't wanna be the next target after xz) (edit: already mitigated by https://github.com/ggerganov/llama.cpp/pull/6409 as pointed out below)

od is used in Makefile (unlike xxd, it should be available on ~all systems, incl. on Windows w/ w64devkit - thanks to busybox), while cmake and zig builds cast their own hex for portability (may have made me n-curse).

ochafik avatar Apr 13 '24 15:04 ochafik