cppast icon indicating copy to clipboard operation
cppast copied to clipboard

Changes required to build cppast with conan

Open Manu343726 opened this issue 6 years ago • 14 comments

This PR adds all the changes I had to do to build cppast using conan to get the dependencies. Basically all dependencies are searched first through find_package() calls (With fallbacks to the old submodule/whatever way).

I'm not sure if you would like the way I search clang through, I'm open for changes and suggestions.

Manu343726 avatar Feb 25 '19 18:02 Manu343726

Looks good so far, I'm just curious about the arbitrary flag and ABI commit.

Also I need to take of foonathan/standardese#123 first.

foonathan avatar Feb 26 '19 16:02 foonathan

About #23, for reference you can check what tinyrefl/tool/externals/externals.cmaje does when not using Conan (find_program(llvm-config) calls with version checks etc)

Manu343726 avatar Feb 26 '19 19:02 Manu343726

(sorry, I'm on mobile)

Sorry, that arbitrary flags patch should not be there, it's something not related to Conan/dependencies. The reason I do that is to pass any flag (not just defines and include dirs) to the libclang parser. Some libs, Qt for example, require extra flags. I will rebase the branch asap to remove that commit from this PR

Manu343726 avatar Feb 26 '19 19:02 Manu343726

The ABI flag is to be able to build on environments using the old gcc ABI with a modern GCC. Conan models that case as part of its os-arch-compiler-stdlib-compilerversion build matrix

Manu343726 avatar Feb 26 '19 19:02 Manu343726

See https://docs.conan.io/en/latest/howtos/manage_gcc_abi.html?highlight=libcxx

Manu343726 avatar Feb 26 '19 19:02 Manu343726

But why can you not do the ABI thing using CMAKE_CXX_FLAGS?

foonathan avatar Feb 26 '19 20:02 foonathan

Any update?

foonathan avatar Apr 08 '19 13:04 foonathan

Sorry for the delay:

But why can you not do the ABI thing using CMAKE_CXX_FLAGS?

I think you're right, I should be able to manage this from the conan side, passing the define explicitly through CMAKE_CXX_FLAGS.

Any update?

I've not patched anything in my fork in the last two months, so if I fix that couple of things you noted this should be ready to merge.

Manu343726 avatar Apr 16 '19 10:04 Manu343726

Hey, what's the current status? :D

foonathan avatar Oct 02 '19 18:10 foonathan

Hi @Manu343726 I am also wondering about this. Or more than this, I hope all is ok. I've been personally benefiting immensely from all of your fantastic contributions to the C++ community over the years particularly around ctti and this kind of work. I'd love to see this get through the finish line. It seems like it was pretty much ready to go by the end here.

kmaragon avatar Jan 07 '20 23:01 kmaragon

I am assuming this has become obsolete according to something you've tweeted?

foonathan avatar May 29 '20 16:05 foonathan

The reason why this PR stagnated was that first we have to figure out how to include libclang into mainstream conan first. There's a work in progress PR in conan-center-index, but it will take some time.

The changes needed in cppast were just about making dependency handling non intrusive, using cmake find_package is the best alternative. The reason why I haven't finished this PR is that I'm not sure what will be the final naming of the libclang package.

Once conan has an official llvm/libclang package I will push this PR again.

Manu343726 avatar May 31 '20 18:05 Manu343726

You let me know when you want this merged, right?

foonathan avatar Jun 23 '20 15:06 foonathan

Of course, don't worry, we just need to figure out llvm first. I'm just patching stuff as bugs appear.

El mar., 23 jun. 2020 17:43, Jonathan Müller [email protected] escribió:

You let me know when you want this merged, right?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/foonathan/cppast/pull/75#issuecomment-648247314, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAL5E3MAFFSCS2UQZ2OPOQ3RYDESRANCNFSM4G2B7F7A .

Manu343726 avatar Jun 23 '20 20:06 Manu343726

Closing this one since nobody worked on this for years. Feel free to reopen.

saraedum avatar Jan 05 '24 15:01 saraedum