{"id":18842927,"url":"https://github.com/m-fatah/hot_reloading_with_cmake","last_synced_at":"2025-07-04T01:34:32.966Z","repository":{"id":111443030,"uuid":"541201612","full_name":"M-Fatah/hot_reloading_with_cmake","owner":"M-Fatah","description":"An example to demonstrate how to implement hot reloading for a game engine and integrate it with CMake.","archived":false,"fork":false,"pushed_at":"2022-09-26T21:04:21.000Z","size":15,"stargazers_count":17,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-14T07:47:26.718Z","etag":null,"topics":["c","cmake","cpp","game-development","game-engine","gamedev","hot-reload"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/M-Fatah.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-09-25T14:39:02.000Z","updated_at":"2025-03-10T10:08:47.000Z","dependencies_parsed_at":null,"dependency_job_id":"8c7da9a8-4cc7-467c-a9ad-e2bdc64a4a69","html_url":"https://github.com/M-Fatah/hot_reloading_with_cmake","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/M-Fatah/hot_reloading_with_cmake","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M-Fatah%2Fhot_reloading_with_cmake","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M-Fatah%2Fhot_reloading_with_cmake/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M-Fatah%2Fhot_reloading_with_cmake/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M-Fatah%2Fhot_reloading_with_cmake/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/M-Fatah","download_url":"https://codeload.github.com/M-Fatah/hot_reloading_with_cmake/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/M-Fatah%2Fhot_reloading_with_cmake/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263431361,"owners_count":23465516,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","cmake","cpp","game-development","game-engine","gamedev","hot-reload"],"created_at":"2024-11-08T02:56:06.478Z","updated_at":"2025-07-04T01:34:32.952Z","avatar_url":"https://github.com/M-Fatah.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- badges: start --\u003e\n[![Build status](https://github.com/M-Fatah/hot_reloading_with_cmake/workflows/CI/badge.svg)](https://github.com/M-Fatah/hot_reloading_with_cmake/actions?workflow=CI)\n\u003c!-- badges: end --\u003e\n---\n\n# **Hot reloading with CMake**\n\n##### An example that demonstrates how to implement hot reloading for a game engine and integrate it with `CMake`.\n##### The code example provided compiles and runs on both `Linux` and `Windows`.\n[hot_reloading_with_cmake.webm](https://user-images.githubusercontent.com/6799254/192156217-d6ae8a05-b6f5-48d3-aa7c-eaaa21dd1c3e.webm)\n\n## **The basic idea behind it:**\nThe engine neeeds to be built as a `dll`.\n- Copy the game engine's `dll` to a new file.\n- Load the copied `dll` from the `platform` layer or a `launcher` at runtime.\n- Every frame check if the original `dll` has been modified and if so unload the copied `dll` and repeat the process.\n- In debug mode, ensure that the generated `pdb` files are named randomly to avoid locking.\n\n## **Platforms:**\n- Linux.\n- Windows.\n\n## **Prerequisites:**\n#### **Linux:**\n- ```sudo apt install -y cmake```\n#### **Windows:**\n- Download and install [CMake](https://cmake.org/download/) (version 3.20 atleast).\n\n## **Building:**\n- Run one of the provided scripts, for example `build_debug.sh` or `build_debug.bat`.\n- Output is in `build/bin/${CONFIG}/` directory.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm-fatah%2Fhot_reloading_with_cmake","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fm-fatah%2Fhot_reloading_with_cmake","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm-fatah%2Fhot_reloading_with_cmake/lists"}