Тёмный

import CMake, CMake and C++20 Modules - Bill Hoffman - CppCon 2022 

CppCon
Подписаться 153 тыс.
Просмотров 26 тыс.
50% 1

cppcon.org/
---
import CMake, CMake and C++20 Modules - Bill Hoffman - CppCon 2022
github.com/Cpp...
Originally developed as part of the National Institutes of Health (NIH) open source medical segmentation and registration toolkit ITK in 1999, CMake has grown to take on a vital role in the C++ ecosystem. Bill Hoffman, a founder of Kitware (www.kitware.com), and the creator of CMake will talk about where CMake is in 2022. The talk will start with a brief history of CMake and how it fits into the world of C++. It will then talk about recent developments to support C++20 modules.
For most of CMake's history, CMake has played catch up and implemented new features as compilers and IDEs have been released. With C++ modules, CMake developers have engaged the standards committee and compiler vendors to help craft the standard in such a way that CMake and other build systems can more seamlessly implement C++ modules. CMake has worked with Fortran modules for many years and has updated the ninja build tool to be able to dynamically update dependency information as it is discovered. To do this CMake requires a Fortran parser built into CMake. For obvious reasons CMake does not want to get into having its own C++ parser. This is the main driving force for pushing this work into the compilers. This talk will go over the road map for CMake C++ module support.
In addition to the history of CMake, C++ module support, this talk will include material covering important CMake features supporting the seamless building, testing and deployment of C++ across most computing platforms. In summary, listeners will learn about CMake origins, the roadmap of C++ module support in CMake and get an overview of the current set of features in CMake.
---
Bill Hoffman
Mr. Hoffman is a founder of Kitware and currently serves as Chairman of the Board, Vice President, and Chief Technical Officer (CTO). He is the original author and a lead architect of CMake, an open source, cross-platform build and configuration tool that is used by hundreds of projects around the world, and he is the co-author of the accompanying text, Mastering CMake. Using his 20+ years of experience with large software systems development, Mr. Hoffman is also a major technical contributor to Kitware’s Visualization Toolkit, Insight Toolkit, and ParaView projects
Mr. Hoffman received a B.S. in Computer Science from the University of Central Florida and an M.S. in Computer Science from Rensselear Polytechnic Institute (RPI). Prior to the formation of Kitware, he spent nine years at the General Electric Corporate Research and Development center, working in the Computer Vision Group. He has planned and taught several graduate-level courses at RPI as well as a course in object-oriented programming at New York University.
__
Videos Filmed & Edited by Bash Films: www.BashFilms.com
RU-vid Channel Managed by Digital Medium Ltd events.digital...
#cppcon #programming #cmake

Наука

Опубликовано:

 

26 сен 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 45   
@djordjepepic1656
@djordjepepic1656 Год назад
Was shocked and impressed to discover the presenter is actually the original author of CMake! Also once I realized this, I also realized that this guy is exactly how I would have imagined the author of CMake to be; smart, easygoing, friendly and here to build some C++! Anyways great talk, definitely very helpful to me in my endeavor of writing a new package manager for C++.
@JaskMar
@JaskMar Год назад
17:00 to skip things we already know about CMake (non-modules-related information)
@TheMR-777
@TheMR-777 Год назад
I thought it's just a usual Cpp talk, opened it, and when got to know he's the creator of CMake, I was mind-blown! It's an honor to have a session with Mr. Hoffman. Moreover, a Great thanks to CppCon as always, for being a source of such valuable knowledge :)
@moamenkhet
@moamenkhet Год назад
Amazing talk, thank you very much!
@ianliu88
@ianliu88 Год назад
C++ is now on par with fortran, congrats!
@dexterman6361
@dexterman6361 Год назад
Can't wait to test this out! Shame cuda isn't catching up! Thank you for the video!
@Omnifarious0
@Omnifarious0 Год назад
I'm really looking forward to when I can use this without compiling custom versions of system packages.
@crea7or
@crea7or Год назад
This is why Rust and other languages getting more attention than C++. Building apps shouldn't be that hard.
@StefaNoneD
@StefaNoneD Год назад
Exactly what I was thinking!
@nandhan6637
@nandhan6637 Год назад
ya lacking simplicity and wastes more time which is precious
@cgazzz
@cgazzz Год назад
This is however an experimental feature to support a huge new experimental feature on 3 different compiler families. Once a CMake pattern is started it's fairly simple to repeat
@TheMaidenOnes
@TheMaidenOnes Год назад
No clang support for modules yet..
@YourCRTube
@YourCRTube Год назад
55:08 A bit confusing mymodule_part_internal.cpp needs to be part of the set, though it does not export. I guess that's because it declares new partition?
@PaulHindt
@PaulHindt Год назад
I would love to see a Python version of CMake, where CMake is simply imported as a module into Python script. Given the steady rise in popularity of the Meson build system, I suspect that there are many other C/C++ developers that share this opinion. I've written both small and largeish build scripts in CMake and, while generally a joy to use, my biggest gripe with CMake is having to learn its dedicated language syntax. To my mind the biggest strength of CMake is not its custom language, but the years of hard-won build system knowledge that KitWare has amassed. Mr. Hoffman sort of touches on this in the video, when he discusses reverse-engineering Visual Studio solutions to create CMake generators. The second biggest strength of CMake is its toolchain and IDE integration.
@petermuller608
@petermuller608 4 месяца назад
Isn't syntax completely arbitrary? It would be trivial to transpile from python to CMake if you restrict your python to the functions available in CMake
@petermuller608
@petermuller608 4 месяца назад
While I love CMake, I really dislike how hard it is to learn the modern style. Even the author of CMake uses legacy style set(CMAKE_CXX_STANDARD...) instead of target_compile_features(...) And it's not because it's slide code, both take up a line. Also complexity cannot be the reason, since he used much more complex generator expressions before. How should a novice learn? Is there something like shellcheck for cmake, warning about the usage of old features?
@egorsozonov7425
@egorsozonov7425 Год назад
It's 2022, C++ is 40 years old, and yet C++ head honchos are still figuring out how to compile a C++ program...
@IllumTheMessage
@IllumTheMessage Год назад
We have to get it juuuuuuust right.
@StefaNoneD
@StefaNoneD Год назад
Still way too complicated compared to modern language toolkits for C#, Java, Rust, Go etc. You really have to study (!) CMake in order to use it professionally. In contrast, the above mentioned languages offer more easy way to use their build systems. Especially Rust with Cargo is very, very easy to use.
@JeremyCoppin
@JeremyCoppin Год назад
Exactly !! Compiling/Linking C++ is the biggest hurdle you will have in any C++ project, not the problem you're trying to solve, no matter how complex that problem is. The second problem is that there are very few 'modules to do common tasks' and if you do find one, see above. I have 10's of abandoned projects because of this, the latest being trying to link paho mqtt which I have working in Java and Python, neither of which gave me any issues.
@llothar68
@llothar68 Год назад
@@JeremyCoppin Ha, if you think compiling and linking is hardest, try deploying. But thats a language independent problem these days.
@Key_Capz_
@Key_Capz_ Год назад
For some reason sstream module in vs 2022 isn't fully working unless you #include it.
@oraz.
@oraz. Год назад
Hold up, you need to build a patched gcc to do this?
@brynyard
@brynyard Год назад
It's nice to have a configure/build tool that finally has sorted out (most) of various IDE&OS build quirks, but I think it's high time that the syntax get revised into anything that follows even just the most basic good practices of a programming language (or like someone mention - can be used like a lib and the config done in python). There's tons of severe issues with things like proper expressions, scoping, variable scoping, argument parsing, return values, debugging tools, quoting, inconsistent naming scheme, etc, and somehow I (and many more!) are really put off using CMake by these deficiencies. While continuing ironing out platform quirks and tool compatibilities are important, it's a bit disconcerting that these things doesn't even seem to even be considered for fixing.
@llothar68
@llothar68 Год назад
You just need to read a good language description. The only one i have seen is not in the online docs but you have to buy this CMake for Professionals book. The online documentation really needs thousands of examples. Look at the PHP documentation which is still the gold standard. And finally we need to add deprecation warnings to all options.
@brynyard
@brynyard Год назад
@@llothar68 sorry, but a better description of CMakes terrible language syntax doesn’t improve it (which incidentally also applies to PHO’s infamously inconcistent standard library). There are no good sources for how to write «good» CMake scripts, quite simply because it’s nigh impossuble given all the quirks one have to incorporate.
@angelmarauder5647
@angelmarauder5647 Год назад
@@brynyard what do you use instead?
@origamibulldoser1618
@origamibulldoser1618 Год назад
Cmake is nice, but it's also hard to ignore that cmake is a build system system.
@origamibulldoser1618
@origamibulldoser1618 Год назад
13 minutes in and cpp20 and modules are not yet mentioned.
@rabutuomr3382
@rabutuomr3382 Год назад
Module!
@LegalizeAdulthood
@LegalizeAdulthood Год назад
I agree: CMake *is* the standard build system for C++.
@DimiterStanev
@DimiterStanev Год назад
If only CMake supported generated .vcxproj with relative paths... When you have thousands of .vcxprojs it's hard to migrate over time.
@discreet_boson
@discreet_boson Год назад
What about support for import std; ?
@pengxie3087
@pengxie3087 Год назад
it seems to be a C++23 standard feature
@Dazza_Doo
@Dazza_Doo 2 месяца назад
If you're trying to claim that you're the official build of C++, Why haven't you built tools, Where is the integration? Where is the place that I go to download your application that then downloads the appropriate complier that I can then link all my projects to
@junaid1464
@junaid1464 Год назад
Honestly not happy with what we have for c++, been thinking around rethinking build system for c++, actually this should be 1st priority of standards community
@petermuller608
@petermuller608 4 месяца назад
The C++ Standard does not know build systems. It barely acknowledges source code is living in "files" Not saying you are wrong, but the standard is the wrong place
@kspangsege
@kspangsege Год назад
Emacs 👍 🙂
@junaid1464
@junaid1464 Год назад
Build system becoming job requirement. :(
@JeremyCoppin
@JeremyCoppin Год назад
It is a job in and of itself.
@ko_fes
@ko_fes Год назад
CMake under windows is a nightmare. 'Couse you can't change compilers/debugger/linker by changing cmake file only (if you want to use utilities that are not packaged by vs installer), - you also must some how setup dev environment and that is not trivial if you don't want to use IDEs and just want to build & run a project by a few commands. And also - why for building cmake project under windows it's necessary to generate a whole bunch of sln-related files, even if you use clang-cl? When Windows developers resolve this problem?
@lmi9f9
@lmi9f9 Год назад
Start over, you're doing it wrong. I don't know Such issuea.
@DFPercush
@DFPercush Год назад
You choose a generator (visual studio project, ninja, make) and a compiler ("specify native compiler" in cmake-gui) during the configure step. That information is in the cache. You might want to just start over with a new build directory if you don't see those options. If you want to use a utility that is not part of the standard compiler toolchain, you probably want to use add_custom_command and add_custom_target. If you need to build a visual studio project without opening the IDE, use msbuild. or cmake --build . But if you don't want any visual studio files, then you probably picked the wrong generator.
@konstantinlimarev2639
@konstantinlimarev2639 Год назад
Cpp modules ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-5X803cXe02Y.htmlm50s
@王靖凯-w7k
@王靖凯-w7k Год назад
牛哇,小三年了,总算要来了!
Далее
Branchless Programming in C++ - Fedor Pikus - CppCon 2021
1:03:57
Introduction to CMake Crash Course
14:08
Просмотров 18 тыс.
iPhone 16 Pro Max - Ochib ko'ramiz
10:54
Просмотров 159 тыс.
iPhone vs Samsung
0:25
Просмотров 10 млн