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

Offline usage: avoid re-downloading glfw and freetype #105

Open
leavittx opened this issue Apr 16, 2024 · 3 comments
Open

Offline usage: avoid re-downloading glfw and freetype #105

leavittx opened this issue Apr 16, 2024 · 3 comments
Labels

Comments

@leavittx
Copy link

Hi!
Sometimes I need to re-generate cmake cache when not connected to the internet.
For example that happens all the time when I switch from Debug to Release configuration and vice versa in Visual Studio.
Hello imgui tends to download freetype and glfw each time.
Would it be possible to cache those locally (maybe as a cmake configure time option)? Also because of that the build time grows significally when you add new source files for example

@pthom
Copy link
Owner

pthom commented Apr 17, 2024

Hello,

Hello ImGui will try to find glfw and freetype via find_package. If it cannot find them, it will try to download them.

I would advise you to install them for example via vcpkg once for all; Thus the download will be skipped.

@pthom pthom changed the title Offline usage Offline usage: avoid re-downloading glfw and freetype Apr 17, 2024
@pthom pthom added the faq label Apr 17, 2024
@leavittx
Copy link
Author

leavittx commented May 5, 2024

I was able to get it working with vcpkg following
https://github.com/microsoft/vcpkg?tab=readme-ov-file#quick-start-windows
and partly https://learn.microsoft.com/en-gb/vcpkg/get_started/get-started?pivots=shell-cmd
(the vcpkg add port <packages> command)
However I had to install lunaswg separately, otherwise the lunasvg.h header wasn't found in imgui_freetype.cpp.
Final install command for the project: vcpkg add port freetype glfw3 lunasvg

@sAkuraOfficial
Copy link
Contributor

I was able to get it working with vcpkg following https://github.com/microsoft/vcpkg?tab=readme-ov-file#quick-start-windows and partly https://learn.microsoft.com/en-gb/vcpkg/get_started/get-started?pivots=shell-cmd (the vcpkg add port <packages> command) However I had to install lunaswg separately, otherwise the lunasvg.h header wasn't found in imgui_freetype.cpp. Final install command for the project: vcpkg add port freetype glfw3 lunasvg

maybe you can: vcpkg install unofficial-lunasvg

find_package(unofficial-lunasvg CONFIG REQUIRED)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants