CMake Tutorial EP 1 | Understanding The Basics

แชร์
ฝัง
  • เผยแพร่เมื่อ 25 ก.ค. 2020
  • full CMake playlist: • CMake Tutorial EP 1 | ...
    Find me, support me:
    Stream: / bytepro17124
    Patreon: / codetechtuts
    One time donations: www.paypal.com/paypalme/matte...
    Shop via my Amazon Affiliates Link: amzn.to/3bVQ9X0
    Business inquiries: codetechtuts@gmail.com
    Thanks for coming to the channel to check out a video on Code, Tech, and Tutorials.
  • แนวปฏิบัติและการใช้ชีวิต

ความคิดเห็น • 230

  • @RuoshiWen
    @RuoshiWen 7 หลายเดือนก่อน +5

    Great tutorial. I do enjoy that you were giving tutorials in a very relaxing tone. I got really stressed when I learn c++ related contents.

  • @opexkoru5157
    @opexkoru5157 3 ปีที่แล้ว

    Best cmake tutorial I've seen by far. Looking forward to watching the rest of the videos. Thanks!

  • @ctjanney
    @ctjanney 2 ปีที่แล้ว

    Fantastic! Thank you. I've struggled with make files, hacking open source setups to compile without direction. Thank you for your clear tutorials.

  • @phillno1751
    @phillno1751 2 ปีที่แล้ว

    Subscribed. Clear, concise, exactly what I need to get started. I look forward to the next video. Thanks!

  • @bestganesh
    @bestganesh 3 ปีที่แล้ว +24

    This is a very nice introduction to Cmake. Really got what I need. Thanks :)

  • @B15HOP
    @B15HOP 2 ปีที่แล้ว +16

    So glad you put this in here. The other good tutorial is "cmake good" by vector-of-bool. The cmake library is a little bit more confusing at first than standard makefiles, but they are worth it because makefiles get bloated and tedious very quickly. As you know, the cmake tools bypass this by creating the project Makefiles for you.

  • @abelashenafi6291
    @abelashenafi6291 2 หลายเดือนก่อน

    Thanks man. The shortest yet most efficient and vivid explanation about Cmake and MakeFile. Thanks a lot man. really. Kudos

  • @motsyrhc7436
    @motsyrhc7436 ปีที่แล้ว

    thank you kind sir. this is the most concise video on CMake I've seen so far.

  • @tiendadelchavo4132
    @tiendadelchavo4132 2 ปีที่แล้ว +9

    These CMake tutorials are simply the best! Amazing explanation and tips! Thank you so much!

  • @mr.bun-bunny8830
    @mr.bun-bunny8830 3 ปีที่แล้ว +3

    I subscribed because your blender tutorial helped me with video editing and now I'm here because of your coding tutorials and I'm Loving It.

    • @mr.bun-bunny8830
      @mr.bun-bunny8830 3 ปีที่แล้ว

      wanted to ask I'm having this g++ error in visual studio code whenever I try to code in C or C++ well it happens when I try to run it any idea how can I solve it?

    • @CodeTechandTutorials
      @CodeTechandTutorials  3 ปีที่แล้ว

      @@mr.bun-bunny8830 hard to say without many specifics. Can you post the source code?

  • @carlosdalomba
    @carlosdalomba 3 ปีที่แล้ว +90

    This was easily the best CMake tutorial/resource I found all week so far.
    I've been struggling to understand all the terms and how it (CMake) fits into everything.
    Especially coming from a Unity/C# game dev background, and not really.. understanding much about "builds", "platforms", and "compilers" besides extreme basics/vagueness.
    Thank you so much, this really makes it feel a lot more doable.
    P.S. - I'm so glad you use VS Code too! Just started with it today as well haha

    • @user-fl5zl6ml5b
      @user-fl5zl6ml5b 2 ปีที่แล้ว

      Sorry to interrupt,i am a newer to learn cmake ,is there any tutorial to recommend? Thanks .

    • @openroomxyz
      @openroomxyz ปีที่แล้ว

      @@user-fl5zl6ml5b same :)

  • @thibautmodrzyk6215
    @thibautmodrzyk6215 3 ปีที่แล้ว +41

    Thanks Our sort of long haired Lord And Savior, I'm struggling with the documentation. Having a human explaining really helps

    • @CodeTechandTutorials
      @CodeTechandTutorials  3 ปีที่แล้ว +3

      You can do it!

    • @AlexAlex-em6ct
      @AlexAlex-em6ct 3 ปีที่แล้ว +3

      @@milanky you put an link to a payed link but here is free basics, not payed

  • @Augnos
    @Augnos 11 หลายเดือนก่อน

    Thanks for explaining makefiles in literally the first 5 minutes. I don’t know how every other explanation skips this part and what cmake is even needed for

  • @cppdog3549
    @cppdog3549 ปีที่แล้ว +3

    I think I just found my favorite TH-cam channel. I really love the joke in the beginning about our Lord and Savior.....CMake, and I really enjoyed watching your tutorial and learning about how CMake works. I love your style of teaching and it's so intuitive. Thank you for making this video.

  • @saeidsaati4021
    @saeidsaati4021 2 ปีที่แล้ว

    This video was great even for me with some experience with cmake, thank you!

  • @kavorka8855
    @kavorka8855 3 หลายเดือนก่อน

    Simple, clear and fun way of teaching any subject! Now, next ... part 2

  • @sammyiboi
    @sammyiboi 3 ปีที่แล้ว +19

    Thanks for this! There's only a few CMake tutorials out there, so this one is definitely welcome :) Just finished the first video. CTT looks awfully close to C++, woah!

  • @jiangpengli86
    @jiangpengli86 2 วันที่ผ่านมา

    Thank you so much for this great tutorial.

  • @ORagnar
    @ORagnar ปีที่แล้ว +1

    I'm getting a Bob Ross vibe from your style. I expect to see some happy little clouds.
    7/14/22, 5:57 p.m.

  • @codinger4182
    @codinger4182 3 ปีที่แล้ว +90

    This guy looks like *_Gilfoyle_* from *Silicon Valley* .
    Jokes apart, he explained great!

    • @hosseinbeiranvand7169
      @hosseinbeiranvand7169 3 ปีที่แล้ว

      exactly man!

    • @makermatrix9815
      @makermatrix9815 3 ปีที่แล้ว +6

      Sounds like him even more than he looks like him, LOL

    • @hridaykeswani6459
      @hridaykeswani6459 2 ปีที่แล้ว

      We will talk about our lord and savior ... what do you think am talking about SATAN! xD

    • @poganka45
      @poganka45 2 ปีที่แล้ว

      he reminds me of Lex Luthor's father

    • @snowman4933
      @snowman4933 2 ปีที่แล้ว

      true af

  • @sunableflames9365
    @sunableflames9365 3 ปีที่แล้ว +3

    Thanks a million for this introductory lesson on cmake.Been looking for a clear tutorial and you sir make it crystal clear!! Please keep making the videos.

  • @Gloryisfood
    @Gloryisfood 2 ปีที่แล้ว +1

    Finished watching the first video and I know I will learn something from the series. Thank you, Sir!

  • @sirtobi6006
    @sirtobi6006 3 ปีที่แล้ว +6

    I came to learn about CMake and directly left an abonoment.

  • @qc2217
    @qc2217 3 ปีที่แล้ว +1

    This is a nice tutorial! Thank you for making it!

  • @it_raman_suryawanshi1399
    @it_raman_suryawanshi1399 ปีที่แล้ว

    Thank you 😊 for making it easy to understand.

  • @lifeisbeautifu1
    @lifeisbeautifu1 3 ปีที่แล้ว +1

    Thanks so much for this great tutorial ! :)

  • @inlovewithtajweed1
    @inlovewithtajweed1 3 ปีที่แล้ว +17

    Thank you for sharing. I enjoyed the content. Minor: zues==>Zeus.

  • @journeyman6856
    @journeyman6856 3 ปีที่แล้ว +12

    The best CMake tutorials on TH-cam!

    • @milanky
      @milanky 3 ปีที่แล้ว

      Checkout the Beginner/Intro CMake Course at www.udemy.com/course/master_cmake/?referralCode=D08DF343ABAE2835C3B7

  • @JaCkuevara
    @JaCkuevara 2 ปีที่แล้ว

    Such a funny guy - and a nice intro - keep it going man! Best Regards

  • @bieldozap
    @bieldozap 3 ปีที่แล้ว +1

    seriously, i was starting to watch the OGRE tutorial and when I saw Cmake, it came to my mind "oh boy it would be nice a Cmake tutorial". And here I am. Thank you so much.

    • @CodeTechandTutorials
      @CodeTechandTutorials  3 ปีที่แล้ว +1

      Nice! I'm studying hard to make this next cmake tutorial and hopefully take it to a whole new level

  • @degancontent1979
    @degancontent1979 ปีที่แล้ว

    Good one, looking forward for part 2

  • @rishabhjain911
    @rishabhjain911 2 ปีที่แล้ว

    Great job bro
    You just made it a piece of cake
    :)

  • @xayanmusic3627
    @xayanmusic3627 25 วันที่ผ่านมา

    very good tutorial thank you for being so clear

  • @anguruso
    @anguruso 8 หลายเดือนก่อน

    Thank you! I had one hell of a time understanding CMake before watching your videos.

  • @saulmorales372
    @saulmorales372 3 ปีที่แล้ว +1

    I appreciate your content and you hella funny!! Thank You Man!!!!!!!

  • @jasonwell5299
    @jasonwell5299 3 ปีที่แล้ว

    Gorgeous video bro.

  • @blankeyezero
    @blankeyezero 3 หลายเดือนก่อน

    thank you.. i was a simple guy coming from interpreted languages... this compiler problem was making things difficult for me as to finding out which c compiler I should use and such...

  • @moshe22cohen
    @moshe22cohen 2 ปีที่แล้ว

    you are indeed a savior.
    had hard time grasping it and your tutorial made it clear, managed to create cmake and compiling thanks!

  • @aogposton
    @aogposton 5 หลายเดือนก่อน

    Came to this after doing my own way.... Thank you for the tutorial.

  • @uwemisrael5836
    @uwemisrael5836 10 หลายเดือนก่อน

    I'm finiding this series very helpfull. Started learning C++. Thanks

  • @huseyink97
    @huseyink97 2 ปีที่แล้ว +1

    thanks for the best introduction!

  • @WhiteBerry
    @WhiteBerry 2 ปีที่แล้ว

    Hi, could you tell me the settings you use for the file path to appear above the first line of the editor? Great video btw

  • @rsmusic-fh6nl
    @rsmusic-fh6nl 2 หลายเดือนก่อน

    only legible cmake explanation i've found, tysm

  • @mupmuptv
    @mupmuptv 3 ปีที่แล้ว

    Thank you. You are the best

  • @dimitrigraur8345
    @dimitrigraur8345 ปีที่แล้ว

    Great material, subscribed!

  • @user-kt8nc4xd1u
    @user-kt8nc4xd1u ปีที่แล้ว

    Thanks for creating this video

  • @mxlodyk
    @mxlodyk 10 หลายเดือนก่อน

    Thank you for this video!

  • @hertzvador2220
    @hertzvador2220 ปีที่แล้ว

    This was very useful. Thank you.

  • @eyalpery8470
    @eyalpery8470 3 ปีที่แล้ว +1

    Excellent! Thanks!

  • @mittelwelle_531_khz
    @mittelwelle_531_khz 2 ปีที่แล้ว +12

    Having watched 5 minutes only I feel already inclined to comment:
    Being a software developer myself for more than 40 years (so "technically" in retirement now but nevertheless still active) I like your intro: there's no single best practice fitting each every project.
    I also like your dry humor - it doesn't escape me. (I think you know what I mean.)

    • @mittelwelle_531_khz
      @mittelwelle_531_khz ปีที่แล้ว +2

      @Harshil Pandey here's a story of those early days: in some versions of _make_ it was hard-coded that when you used it for the target "love", i.e. you ran it as:
      *make love*
      It responded:
      *not war*

  • @avinashmehtadelhi
    @avinashmehtadelhi ปีที่แล้ว

    Great video, many thanks. Would be great if u can plan a playlist on configure make and make install. 👍

  • @thefrostian
    @thefrostian 3 ปีที่แล้ว

    Fantastic. Thanks so much.

  • @mikey.audio.
    @mikey.audio. ปีที่แล้ว

    excellent content, thanks!

  • @john3932
    @john3932 3 ปีที่แล้ว

    Fantastic tutorial
    Cheers m8

  • @moeroe7663
    @moeroe7663 3 ปีที่แล้ว +1

    As a C-noob I can say: this is really helpfull!

  • @davidnguyen9023
    @davidnguyen9023 ปีที่แล้ว

    Simply great.

  • @DevCurioso
    @DevCurioso 3 ปีที่แล้ว +1

    Great intro to Cmake, congrats

  • @DanRed-bc3ug
    @DanRed-bc3ug ปีที่แล้ว

    Thank you so much!
    I also liked the terminal, what is it?

  • @legitjimmyjaylight8409
    @legitjimmyjaylight8409 3 ปีที่แล้ว +2

    It appears I don't have the `-S` option available on my CMake, and it wants to use my `-B` option as both the build and the source directory. It seems this may be because my cmake is out of date, and this is a newer option. My cmake version is 3.10.2.
    Edit:
    I've managed to get it updated now to cmake version 3.20.1, and now I can finally use the `-S` option & follow along with this tutorial.

  • @russellshahenian2357
    @russellshahenian2357 ปีที่แล้ว

    I love it: 'so just please don't' .... i know your're real at that point. Ty great 'simple' effective.

  • @77and619
    @77and619 2 ปีที่แล้ว

    cool guy and gets to the point ! not always like this! tyvm

  • @finrei
    @finrei 2 ปีที่แล้ว

    Actually awesome video series

  • @jimbalta
    @jimbalta ปีที่แล้ว

    Thanks a lot for this tutorial. I went to look up how to use cmake and the tutorial in the official cmake documentation was... not great in my opinion. This helped out a ton.

  • @pdxfunk
    @pdxfunk 8 หลายเดือนก่อน

    Thanks so much for making this. After struggling setting up my IDE for making embedded code for RP2040 processor, I kept being like "WTF actually IS CMAKE??". Now I know.

  • @akashgillella
    @akashgillella ปีที่แล้ว

    Very nice tutorial. Really funny 2! Thanks

  • @Account-fi1cu
    @Account-fi1cu 2 ปีที่แล้ว

    Hi thank you for this great tutorial,
    If I have a solution on windows, is it possible to create a makefile using cmake ?

  • @juan-jh1qg
    @juan-jh1qg 3 ปีที่แล้ว +2

    In windows, run instead the following CMake command:
    > cmake -S ../../ -B . -G "MinGW Makefiles"

    • @thedeathchimera
      @thedeathchimera 3 ปีที่แล้ว

      Thanks man, it kept spitting out visual studio files and I wasn't sure why

    • @abdullahsulaymaan9085
      @abdullahsulaymaan9085 ปีที่แล้ว

      thanks bro, you saved me time

  • @MyMjrox
    @MyMjrox 14 วันที่ผ่านมา

    Still the best cmake tutorial

  • @charles9571
    @charles9571 2 ปีที่แล้ว +1

    Thanks, and nice tutorial.
    - A Christian

  • @markharrington5826
    @markharrington5826 3 ปีที่แล้ว

    Superb thank you

  • @AdityaDendukuri
    @AdityaDendukuri 3 ปีที่แล้ว

    Great video! Could you explain more why do you build in ./out/build instead of ./build?

    • @CodeTechandTutorials
      @CodeTechandTutorials  3 ปีที่แล้ว +1

      At the time, it was because if you let Visual Studio configure your cmake project, it uses out/build Nowadays I went back to just ./build

  • @xugefu
    @xugefu 2 ปีที่แล้ว

    Thanks!

  • @deryaadil4344
    @deryaadil4344 ปีที่แล้ว

    How can I change the compiler architecture options used by cmake by adding some instructions to the cmake call? Thank you so much!

  • @syzygy8060
    @syzygy8060 2 ปีที่แล้ว

    Hey man! Thanks for your well-explained video. You got me up and running. Cheers.

  • @HY-nt8nk
    @HY-nt8nk 3 ปีที่แล้ว +7

    In cmake, where did we mention the kind of compiler to use? At the beginning of the video, in the makefile, it was explicitly mentioned to use 'g++' compiler. But, I did not get how cmake picked the compiler? Can you please answer me this question?

    • @Karlthegreat100
      @Karlthegreat100 2 ปีที่แล้ว

      I'm not sure if there are other ways but I usually set environment variables for that, specifically, CC and CXX. So
      CC=/path/to/clang CXX=/path/to/clang++ cmake..

  • @8Trails50
    @8Trails50 2 ปีที่แล้ว

    I wish all tutorials were like this

  • @gopinath6946
    @gopinath6946 ปีที่แล้ว

    You said No standard in coding.... Thalaiva You are great...

  • @openroomxyz
    @openroomxyz ปีที่แล้ว

    What cmake does that Visual Studio under windows does not? What is the advantage over using Visual Studio?
    Correct me if I am wrong but I got the impression that to learn cmake is best not to use IDE and do it under linux, to create your build system? I heard something called premake not sure how are they different?

  • @double-lung7364
    @double-lung7364 2 ปีที่แล้ว

    Thanks for the tutorial! Which distro are you using in this video?

  • @davenarisotto3674
    @davenarisotto3674 2 ปีที่แล้ว +1

    There's one thing I can't seem to understand: does cmake substitute normal compilation and execution with g++?
    For example: usually whenever i start programming a new project, i write the code, then i use g++ to compile the whole project and then i run the outputted executable.
    Does cmake substitute this process?

    • @ItsSunnyMonster
      @ItsSunnyMonster 2 ปีที่แล้ว +1

      CMake only generates project files for each compiler/platform. If you use Windows and Visual Studio, you can use CMake to generate Visual Studio solution files. If you use Mac and XCode you can use CMake to generate XCode projects, etc etc. This is very convenient because you just need to write the CMake lists files and have CMake generate project files on all platforms so you can compile the generated projects. Hope that answers your question.

  • @ascyrax8507
    @ascyrax8507 ปีที่แล้ว

    thank u.

  • @lyndazaid9560
    @lyndazaid9560 ปีที่แล้ว

    thank you so much,it was helpful.
    please sir i have a question ,i tried to build a project with cmake but in it's configuration it throws an error:could not load cache.I tried all the solution but without getting any results.Could you please help me.
    thnak you again

  • @katjordansoccer
    @katjordansoccer 8 หลายเดือนก่อน +1

    Zeus, not Zues, but otherwise really well done. Thanks!

  • @meenamurthy1503
    @meenamurthy1503 ปีที่แล้ว

    You could say cmake creates a make file, easier ro to associate c with create

  • @maryguty1705
    @maryguty1705 3 ปีที่แล้ว

    could you do a video on adding other's complied SDK and API libs in Cmakelist for coding?

    • @CodeTechandTutorials
      @CodeTechandTutorials  3 ปีที่แล้ว +1

      I could do that. Any certain api you want to see as an example?

  • @enveraaa8414
    @enveraaa8414 2 ปีที่แล้ว

    Thanks

  • @elektronicznyjuzek9910
    @elektronicznyjuzek9910 ปีที่แล้ว

    epic!

  • @tiendadelchavo4132
    @tiendadelchavo4132 2 ปีที่แล้ว

    Valeu!

  • @vinniciusrosa8284
    @vinniciusrosa8284 4 หลายเดือนก่อน

    How can I change the compiler to MingW? I tried a lot of things and I did not found the answer through the internet. :(

  • @timsessions1845
    @timsessions1845 ปีที่แล้ว

    Praise be to cmake

  • @oneday374
    @oneday374 ปีที่แล้ว

    we want you can do a video en the windows version.

  • @Alexey_Pe
    @Alexey_Pe 2 ปีที่แล้ว

    Балдёж)

  • @Reuged666
    @Reuged666 ปีที่แล้ว

    can i use the same tutorial for code::blocks?

  • @Evilanious
    @Evilanious 4 หลายเดือนก่อน

    I cannot believe this contains such basic errors that will mislead beginning programmers. It's spelled 'Zeus'! Get it together!
    Seriously though, thanks. This was very helpful.

  • @JasonKT13
    @JasonKT13 ปีที่แล้ว

    What OS are you using here?

  • @user-cq3kj1cn8e
    @user-cq3kj1cn8e 4 หลายเดือนก่อน

    can you do cmake for yocto or if you arleady did give me link for that

  • @kamiltrzcinski
    @kamiltrzcinski ปีที่แล้ว +2

    gives off strong 2011 vibes

  • @justdoingodswork
    @justdoingodswork 9 หลายเดือนก่อน

    I tried to make a makefile, but terminal is not reconizing command make?

  • @codutyapexpredator1548
    @codutyapexpredator1548 หลายเดือนก่อน

    I think I stumbled into the real life Gilfoy. 😂😂😂

  • @pygeekrfoo820
    @pygeekrfoo820 10 หลายเดือนก่อน

    thank you gilfoyle