{"id":21022580,"url":"https://github.com/h4tr3d/cmakeprojectmanager2","last_synced_at":"2025-04-09T19:19:46.076Z","repository":{"id":19865330,"uuid":"23128795","full_name":"h4tr3d/cmakeprojectmanager2","owner":"h4tr3d","description":"Enhanced CMake Project Manager plugin for Qt Creator","archived":false,"fork":false,"pushed_at":"2025-03-10T03:15:54.000Z","size":3451,"stargazers_count":74,"open_issues_count":4,"forks_count":9,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-04-09T19:19:41.951Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/h4tr3d.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2014-08-19T23:12:37.000Z","updated_at":"2025-03-10T03:15:57.000Z","dependencies_parsed_at":"2023-02-10T00:45:56.317Z","dependency_job_id":"decacade-ba37-4f2f-b4f9-dcae050bc8af","html_url":"https://github.com/h4tr3d/cmakeprojectmanager2","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4tr3d%2Fcmakeprojectmanager2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4tr3d%2Fcmakeprojectmanager2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4tr3d%2Fcmakeprojectmanager2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/h4tr3d%2Fcmakeprojectmanager2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/h4tr3d","download_url":"https://codeload.github.com/h4tr3d/cmakeprojectmanager2/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248094991,"owners_count":21046770,"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":[],"created_at":"2024-11-19T11:12:52.045Z","updated_at":"2025-04-09T19:19:46.053Z","avatar_url":"https://github.com/h4tr3d.png","language":"C++","readme":"CMakeProjectManager2\n====================\n\n**NOTE: Project are discontinued and repository will be frozen. Use upstream plugin that started to be more usable that this one. Now it contains next killer features:**\n- **Edit relative target sources entries in the CMakeLists.txt when new files added/created**\n- **It still does not display all files, but it can be simple work arounded via adding needed files (without impact existing project structure): [https://github.com/h4tr3d/qtc-other-files-helper](https://github.com/h4tr3d/qtc-other-files-helper?tab=readme-ov-file#per-project-configuration-without-any-ide-impact) ([short description in Russian](https://htrd.su/blog/2023/08/18/qtc-other-files-helper/))**\n- **Vcpkg integration**\n\nAlternative CMake support for Qt Creator.\n\nMain differents from original CMakeProject plugin:\n\n* Project file list readed from file system instead of parsing .cbp (CodeBlocks) project file.\n  It can be slow on big projects, but reloading initiating only during open project, run CMake,\n  or user-initiated tree changes (add new files, erase files, rename file)\n* ~You can add new files from Qt Creator. Note, you can create file outside project tree,\n  but Qt Creator will display only files that present in project tree. Also, you should\n  manualy describe this files in CMakeLists.txt~ *NOTE:* done in the more proper way in the upstream.\n* ~You can rename files in file system from Qt Creator now.~ *NOTE:* done in the more proper way in the upstream.\n* ~You can erase files from files system from Qt Creator now.~  *NOTE:* done in the more proper way in the upstream.\n* Classic tree view for CMake Server mode (uses automatically with CMake \u003e= 3.7)\n\nThis functionality is not compatible with QtC Project View idea: **Project View == Build System view**. So, upstream accepts only changes that can be done via build system tools and API.\nCMake does not provide way to modify CMakeLists.txt and related files, add/remove/rename file to targets and so on. So such changes in plugin (different kinds of work arounds) will be\ndropped. But in my opinion: usability of IDE must be putted to first place. If some kind of WA that simplify work with CMake cab be implemented - it must be implemented.\n\n\n\nBuild plugin\n------------\n\nThis plugin is oriented to latest Git version of Qt Creator, sorry I use it and I have no time\nto support other stable versions.\n\n\n\n### Prepare Qt Creator\n\nCommit 9d8a419d107ae8219c84bc9178bfed76b94fa930 of the Qt Creator completely remove build using `qmake`. So, instruction updated to build plugin with CMake.\n\nIf you have QtC binary installation that contains `lib/cmake/QtCreator` and headers you should not do anything.\n\nOtherwise, you must get full copy of the Qt Creator from the Git, build it and install to some prefix.\n\nFor example, all actions runs in directory `/tmp/qt-creator`\n\n- Take full Qt Creator source tree from Git:\n\n    ```bash\n    git clone https://github.com/qtproject/qt-creator.git qt-creator\n    ```\n\n- Create Qt Crator build tree:\n\n   ```bash\n    mkdir qt-creator-build\n    cd qt-creator-build\n   ```\n\n- Create shadow build:\n\n    ```bash\n    cmake -DCMAKE_BUILD_TYPE=Release \\\n          -DCMAKE_INSTALL_PREFIX=/opt/qtcreator-git \\\n          -DCMAKE_PREFIX_PATH=/usr \\\n          ..\n    # CMAKE_PREFIX_PATH needed to point right location of the LLVM\n    ```\n\n- Build and install it\n\n    ```bash\n    cmake --build . -j 8 \u0026\u0026 \\\n    sudo cmake --install . \u0026\u0026 \\\n    sudo cmake --install . --component Devel\n    # Devel strongly are needed\n    ```\n  - Latest QtC missed `tl_expected` packages, copy it manually\n    ```bash\n    cp -a \"$qtc_source/src/libs/3rdparty/tl_expected\" \"$PREFIX/include/qtcreator/src/libs/3rdparty/\"\n    ```\n\nAlso, refer to the next page for more details:\n\n* https://wiki.qt.io/Building-Qt-Creator-Packages\n\n\n\n### Build plugin\n\n- Change directory to `/tmp/qt-creator`\n\n- Take sources of CMakeProjectManager2 from repository\n\n- Create directory for shadow build:\n  ```bash\n  mkdir cmakeprojectmanager2-build\n  cd cmakeprojectmanager2-build\n  ```\n  \n- Configure plugin:\n  ```bash\n  cmake -DCMAKE_PREFIX_PATH=\"/opt/qtcreator-git\" \\\n        -DCMAKE_INSTALL_PREFIX=\"/opt/qtcreator-git\" \\\n        ../cmakeprojectmanager2-git/\n  # CMAKE_PREFIX_PATH strogly needed if QtC installed to the non-default CMake prefix (/usr in most cases)\n  ```\n  Build:\n  \n  ```bash\n  cmake --build . -j 8\n  ```\n  \n- Install\n  \n  ```bash\n  sudo cmake --install .\n  ```\n\nRestart Qt Creator, go to Help -\u003e About plugins and turn off default CMakeProjectManager plugin.\n\n\n\n### Build plugin from Qt Creator\n\n- Open `cmakeprojectmanager2-git/CMakeLists.txt`, go to Projects layout (see left panel)\n- Look to Build Steps section and add next params for CMake:\n  ```bash\n  -DCMAKE_PREFIX_PATH=\"/opt/qtcreator-git\"\n  ```\n\nNow you can build plugin from Qt Creator.\n\nAlso, refer to the Qt Creator WiKi about plugins development:\n\n* https://doc.qt.io/qtcreator-extending/first-plugin.html\n* https://bugreports.qt.io/browse/QTCREATORBUG-22514\n\n\n\nPrebuilt binaries\n-----------------\n\nUnsupported anymore. Sorry, just have no a time :-(\n\n\n\nTODO \u0026 Roadmap\n--------------\n\nActual tasks and todo can be looks at the Issue page: https://github.com/h4tr3d/cmakeprojectmanager2/issues\n\n\n\nSync with Qt Creator upstream plugin\n------------------------------------\n\n1. Update Qt Creator git repository, moves to the master branch\n2. Create patches for new changes\n```\ngit format-patch \u003cREVISION_SINCE\u003e -- src/plugins/cmakeprojectmanager\n```\nREVISION_SINCE can be found via 'git log' by comments or Change-Id.\n3. Go to CMakeProjectManager2 source tree and change branch to the `qtc-master`\n4. Copy patches from the step 2 to the CMakeProjectManager2 source tree root\n5. Apply patches:\n```\ngit am -p4 *.patch\n```\n6. Change branch to the `master`, merge new changes and resolve conflicts\n","funding_links":[],"categories":["Other"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fh4tr3d%2Fcmakeprojectmanager2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fh4tr3d%2Fcmakeprojectmanager2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fh4tr3d%2Fcmakeprojectmanager2/lists"}