CMake + nmake ããã¸ã§ã¯ã
æ¦è¦
CMake + nmake(MSVC) + VSCode + DirectXã®ããã¸ã§ã¯ããµã³ãã«ãä½ã£ã¦ã¿ã
çç±
ä»æ¥ãVSCodeã§è²ããªè¨èªã®ãã©ã°ã¤ã³ãåºã¦ããVSCodeã§è²ããªè¨èªã®éçºãã§ããããã«ãªã£ã¦ãã¦ãããä¾ãã°TypeScript/JavaScriptã¯è¨ãããããªãJava, Scala, C#, Ruby, Python, Go, Rustãªã©ãªã©â¦ è¨èªãã¨ã«IDEãå¤ããã®ã¯æä½ãè¦ãç´ãã¦å¤§å¤ã ããVSCodeã¯ã¨ãã£ã¿ã¨ãã¦å¿«é©ãªã®ã§ãããããéçºç°å¢ãVSCodeã«ã¾ã¨ãããã¨æã£ããããã§Visual StudioããVSCodeã«å¼ã£è¶ããã¦ã¿ããã¨æãç«ã£ãã®ã§ããã
æ§æ
æ±ç¨çãªCMakeããã¸ã§ã¯ãã¯ä»¥åä½ã£ããã¨ããã£ã¦ãWindowsã§ãLinuxã§ãåããããªãã®ã¯ä½ã£ããã¨ããããä»åã¯Visual Studioããã®ç§»è¡ã¨ãããã¨ã§Windowsã«ç¹åãã¦è¦ããã¨æã£ããåã¯DirectXãæ¸ããã人ãªã®ã§ãVSCodeã§DirectXã®ããã¸ã§ã¯ããç°¡åã«ãã«ã&å®è¡ã§ããã¨ããã¾ã§ãã´ã¼ã«ã¨ãããWindowsã®CMakeã¯ããã©ã«ãã®ã¸ã§ãã¬ã¼ã¿ã¼ã«Visual Studioãæå®ãã¦ããããã«ãããããã«ä¸ã Visual Stuidoãèµ·åããã®ã§ã¯VSCodeã ãã§å®çµãã¦ããã¨ã¯è¨ããªãããä½ããã®CLIç°å¢ã§ãã«ããããã¨æã£ããã¨ããããã§ã¸ã§ãã¬ã¼ã¿ã¼ã®ä¸ã ã¨nmakeãä¸åº¦è¯ãã£ãã
setup.batã§vcvars64.batãå®è¡ããã¹ãéããbuildãã£ã¬ã¯ããªãã¯ãªã¼ã³ãã¦ãbuild.batãå¼ã³åºããbuild.batã¯cmakeãå®è¡ãã¦nmakeãå®è¡ãã¦ã¨ã©ã¼ããªããã°å®è¡ãã¡ã¤ã«ãå¼ã¶ããã«ãã¦ããã
ä»å¾
Debug, Releaseãã¨ã®ãªãã·ã§ã³ãçãã£ãããã¾ã ã¾ã æå®ãã¦ãªããªãã·ã§ã³ãããã¨æã£ã¦ããããã£ã¨æ±ç¨çãªbatãCMakeLists.txtã¯æ¸ããã¨æããä»å¾ã®èª²é¡ã«ããã
ã¾ããä»å¾Visual Studioã使ããªããã¨è¨ãã¨ãããªãã¨ã¯ãªãã¦ã並åå¦çã®ãããã°ãDirectXã®ã°ã©ãã£ãã¯ã¹ã®ãããã°ããJust My CodeããWatchã®è¡¨ç¤ºãªã©ãªã©ãããã°ã«é¢ãã¦ã¯Visual Studioã¯ããªãåªç§ãªã®ã§ãç°¡åãªãããã°ãªãVSCodeã®ã¾ã¾ã§ãè¯ããã§ããã©ãè¤éãªãããã°ãããããªã£ãã¨ãã¯ã¸ã§ãã¬ã¼ã¿ã¼ã«Visual Studioãæå®ãã¦slnãã¡ã¤ã«ãçæãã¦Visual Studioã§ãããã°ããã¨æãã¾ãã