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

add conan and cmake ways to build libconfuse #169

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AndreiCherniaev
Copy link

@AndreiCherniaev AndreiCherniaev commented Jan 31, 2023

I suggest to add new modern way to build libconfuse. It was tested on Ubuntu 22 with conan 2.0, works ok. Thanks for help.

Build & Install

using conan (better)

mkdir my_genimage && cd my_genimage

//to uninstall conan use: pip uninstall conan

//install conan

pip install conan --pre --user
pip install conan --user --upgrade

//download test example

git clone https://github.com/libconfuse/libconfuse

//put to original libconfuse/ folder files CMakeLists.txt and config.h.in (replace) and conanfile.txt

cd libconfuse/

rm -Rf build/

conan profile detect --force

conan install . --output-folder=build --build=missing

cd build

cmake .. -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake -DCMAKE_BUILD_TYPE=Release

cmake --build .

sudo checkinstall --pkgname="libconfuse" --nodoc --pkgversion="1" --default

//to remove use: dpkg -r build-libconfuse

using cmake only

mkdir my_genimage && cd my_genimage

mkdir build-libconfuse

git clone https://github.com/libconfuse/libconfuse

//put to original libconfuse/ folder files CMakeLists.txt and config.h.in (replace)

cd libconfuse/

cmake -S libconfuse/ -B build_libconfuse/ -DCMAKE_BUILD_TYPE=Release

cmake --build build_libconfuse/ --parallel

cd build_libconfuse/

sudo checkinstall

//to remove use: dpkg -r build-libconfuse

P.S. If you still haven't conan install and update it:

pip install conan --pre --user
pip install conan --user --upgrade

Co-Authored-By: myd7349 myd7349@gmail.com

I suggest to add new modern way to build libconfuse. It was tested on Ubuntu 22, works ok.

Build & Install
---------------

**using conan (better)**

mkdir my_genimage && cd my_genimage

//to uninstall conan use: pip uninstall conan

//install conan

pip install conan --pre --user
pip install conan --user --upgrade

//download test example

git clone https://github.com/libconfuse/libconfuse

//put to original libconfuse/ folder files CMakeLists.txt and config.h.in (replace) and conanfile.txt

cd libconfuse/

rm -Rf build/

conan profile detect --force

conan install . --output-folder=build --build=missing

cd build

cmake .. -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake -DCMAKE_BUILD_TYPE=Release

cmake --build .

sudo checkinstall --pkgname="libconfuse" --nodoc --pkgversion="1" --default

//to remove use: dpkg -r build-libconfuse

**using cmake only**

mkdir my_genimage && cd my_genimage

mkdir build-libconfuse

git clone https://github.com/libconfuse/libconfuse

//put to original libconfuse/ folder files CMakeLists.txt and config.h.in (replace)

cd libconfuse/

cmake -S libconfuse/ -B build_libconfuse/ -DCMAKE_BUILD_TYPE=Release

cmake --build build_libconfuse/ --parallel

cd build_libconfuse/

sudo checkinstall

//to remove use: dpkg -r build-libconfuse

Co-Authored-By: myd7349 <myd7349@gmail.com>
@troglobit
Copy link
Collaborator

As one of the maintainers, who also do not like or want to maintain cmake (or conan for that matter), I do not approve this PR.

Other maintainers may feel differently, and may be willing to take care of it. If so, please speak up.

@AndreiCherniaev
Copy link
Author

Diar @troglobit @cgzones I still think libconfuse needs CMake... Do you change your opinion?

@troglobit
Copy link
Collaborator

Diar @troglobit @cgzones I still think libconfuse needs CMake... Do you change your opinion?

No, I have not.

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

Successfully merging this pull request may close these issues.

None yet

2 participants