You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@graphar.apache.org by "yangxk1 (via GitHub)" <gi...@apache.org> on 2025/12/15 09:37:20 UTC
[I] feat(c++): Improve CMakeLists.txt for portable library distribution and installation [incubator-graphar]
yangxk1 opened a new issue, #810:
URL: https://github.com/apache/incubator-graphar/issues/810
### Describe the enhancement requested
rel: #806
The current CMakeLists.txt in GraphAr does not fully support robust distribution and installation of the library. This issue proposes a comprehensive update to:
- Generate install targets for library components and headers
- Export CMake config files for `find_package` support in downstream projects
- Ensure headers, artifacts, and dependencies are correctly installed
- Facilitate use in various build systems and package managers
These enhancements will improve the adoption and packaging of GraphAr for both users and external contributors.
### Component(s)
C++
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For additional commands, e-mail: commits-help@graphar.apache.org
Re: [I] feat(c++): Improve CMakeLists.txt for portable library distribution and installation [incubator-graphar]
Posted by "tanmoyPaul12 (via GitHub)" <gi...@apache.org>.
tanmoyPaul12 commented on issue #810:
URL: https://github.com/apache/incubator-graphar/issues/810#issuecomment-3695898155
@yangxk1 Thanks for the detailed guidance and the draft. I’ll follow the hybrid linking approach you suggested and make sure the RPATH is set correctly
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For additional commands, e-mail: commits-help@graphar.apache.org
Re: [I] feat(c++): Improve CMakeLists.txt for portable library distribution and installation [incubator-graphar]
Posted by "tanmoyPaul12 (via GitHub)" <gi...@apache.org>.
tanmoyPaul12 commented on issue #810:
URL: https://github.com/apache/incubator-graphar/issues/810#issuecomment-3695008304
Hi! I’m interested in working on this issue
Planned approach:
>Add proper CMake install() rules for libraries and public headers
>Export targets and generate CMake config files to support find_package(GraphAr)
>Validate installation and usage from a minimal downstream project
Please let me know if this works for you. Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For additional commands, e-mail: commits-help@graphar.apache.org
Re: [I] feat(c++): Improve CMakeLists.txt for portable library distribution and installation [incubator-graphar]
Posted by "yangxk1 (via GitHub)" <gi...@apache.org>.
yangxk1 commented on issue #810:
URL: https://github.com/apache/incubator-graphar/issues/810#issuecomment-3695603035
Hi @tanmoyPaul12 , thanks for claiming this!
While working on the CMake configuration, could you please consider the following linking strategy to ensure the distribution is robust?
1. Hybrid Linking:
- Dependencies built from source (bundled) should ideally be statically linked (e.g., by forcing BUILD_SHARED_LIBS=OFF for those targets). This keeps the installation self-contained.
- System dependencies can remain dynamic (or whatever the system provides).
2. RPATH Configuration:
- For dynamic linking, please ensure CMAKE_INSTALL_RPATH is correctly set (e.g., using $ORIGIN on Linux) so that users don't need to manually configure LD_LIBRARY_PATH to run the installed library.
The following is the ideal rendering proposed by @Sober7135
<img width="775" height="421" alt="Image" src="https://github.com/user-attachments/assets/750c9a28-dbb2-434f-aec1-4bf747b0440f" />
I also wrote a draft, hope it helps. https://github.com/yangxk1/incubator-graphar/blob/810-improve-cmakelist-library-distribution/cpp/CMakeLists.txt
cc @Sober7135
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@graphar.apache.org
For additional commands, e-mail: commits-help@graphar.apache.org