Home
Le système de construction logicielle CMake
Contents
1. Page 1 of 3 Where is the source code home castagne temp test cmake Browse Source CMAKE_AR Ausr bin ar CMAKE BUILD TYPE Where to build the binaries home castagne temp test cmake build v Browse Build CMAKE_COLOR_MAKEFILE N Search Grouped Mi Advanced ap Add Entry Remove Entry CMAKE_C COMPILER usr bin gcc CMAKE_C_FLAGS CMAKE_C_ FLAGS DEBUG CMAKE_C_FLAGS_MINSIZEREL 0s DNDEBUG CMAKE_C_FLAGS_RELEASE 03 DNDEBUG CMAKE_C_FLAGS_RELWITHDEBINFO 02 CMAKE_EXE_LINKER_FLAGS CMAKE_EXE_LINKER_FLAGS_DEBUG CMAKE_EXE_LINKER_FLAGS_MINSIZE CMAKE_EXE_LINKER_FLAGS_RELEASE CMAKE_EXE_LINKER_FLAGS_RELWITH CMAKE_EXPORT_COMPILE_COMMANDS OFF Name Value La CMAKE_INSTALL_PREFIX usr local CE CMAKE_LINKER usr bin ld Press Configure to update and display new values in red then press Generate to generate selected build files CMAKE AR Path to a program Configure _ Generate Current Generator Unix Makefiles l Press enter to edit option CMake Version 2 8 8 Press c to configure Press g to generate and exit Press h for help Press q to quit without generating Press t to toggle advanced mode Currently On H Le CMake build system Castagnede Cedric June 19th 2012 13 Build and install step e Some important variables to e control the build type MAF SONDE RIDE omg Ine hoes e control the install directory CMAKE INSTALL PREFIX
2. P ef INVENTORS FOR THE DIGITAL WORLD Castagn de C dric June 19th 2012 Outline 1 Motivations of a build system 2 CMake build system 3 Test integration 4 Packaging 5 Release engineering Inria 4 Cnr a CMake build system Castagn de C dric June 19th 2012 2 Motivations of a build system Le CMake build system Castagnede Cedric June 19th 2012 3 What problems do build system solve e For a developer e reduce the time spent in the cycle edit compile test cycle e compile only what is necessary in the source code e Fora development team e generate packages e run tests e generate documentation e Fora user e install software easily e have understandable error during install phase e tune installation 4 Le CMake build system Castagnede Cedric June 19th 2012 4 Build a software a lot of evil ways Examples e will do a script to launch all my command and will be ok e system dependent all path dependent etc e high cost for developers and users e will do a makefile with a make inc my software earns portability e cosily for the user manual configuration e portable customizable e Etc 4 Le CMake build system Castagnede Cedric June 19th 2012 5 Features of a build system 1 e automatic dependency management of source code e compile only the modified sources files and thiers dependencies e software portability e use na
3. htto www cmake org cmake resources software html gt configure prefix lt path gt gt make gt make install e Or install form your distribution e Be careful e about the version of CMake e CMake is needed to build and install your software H Lrar a CMake build system Castagnede C dric June 19th 2012 10 Manage a project with CMake CMakeLists txt e CMakeLists txt describes the project e fist of source files e library to link with e CMakeLists txt is e machine independent CMakeCache txt e common for all users e CMakeCache txt Is e generated by calling cnake lt path_to_source gt e GUI ccmake or cmake gui Makefile e machine specific H Cnr a CMake build system Castagn de C dric June 19th 2012 11 Configuration build and install step e Two way o configure the project e _In source e Out of source 2 CE Eer Lo SOURCE EE et o sulle gt mee e HOH LE E L EE GEO SOUL ce IMSS AUE e Possibility to choose makefile generator during configuration EN ASAS or G O e Sire e After configuration build and install step can be launch gt make gt mn Rens ea H Le CMake build system Castagn de C dric June 19th 2012 12 Configuration with GUI e ccmake lt path_ to source gt e cmake gui lt path to source gt Terminal ei a 5 la CMake 2 8 8 home castagne temp test cmake build D Fichier Edition Affichage Rechercher Terminal Aide File Tools Options Help
4. 012 27 Release engineering Inria Some platform to help you e Continuous integration e Hydra local platform status OK contact sed bordeaux inria fr e Cl Inria national platform status standby contact sed lille inria fr e CDash national platform status OK contact http cdash inria fr CDash e Porting e PIPOL national platform status ON OFF soon contact http pipol inria fr 4 Le CMake build system Castagnede Cedric June 19th 2012 29 To conclude a CMake build system Castagn de C dric June 19th 2012 30 Some conclusions e About build system e manage the relationship developer s user s e About CMake CTest CPack e easy to develop e multi platform e warning reinventing the wheel and making it square 4 La CMake build system Castagnede Cedric June 19th 2012 31 Thank you
5. Lists txt in the top directory e tests CMakeLists txt looks like lrar a CMake build system Castagnede C dric June 19th 2012 22 Using CTest e Get the list of tests e Launch tests e Get log files Le CMake build system Castagn de C dric June 19th 2012 23 Packaging CMake build system Castagn de C dric June 19th 2012 24 about CPack e CPack comes with CMake e ltcan be use without CMake e It allows to e generate a source distribution e generate different binary package ia Cnr a CMake build system Castagn de C dric June 19th 2012 25 Introduction to CPack without CMake e Write a file named CPackContig cmake or CPackSourceConfig cmake that looks like SET CPACK_ GENERATOR NG SET CPACK PACKAGE NAME MY SOFT SET CPACK PACKAGE VERSION MAJOR re SITE COPA EE WIE RS ION NOE D SEKR RE RC EAO EO EEDE EES Ibs CHE DIRECTORY COIR E HE SEET SUM EEN Si SOURCE DLC a SIDE ANOS LBE CHAINE IRIN OWI Is es SI TC PAC AN MII HE SET Generate package SERRE CMake build system Castagnede C dric June 19th 2012 26 Introduction to CPack with CMake e Add in your CMakeLists txt INCLUDE InstallRequiredSystemLibraries HACIA CINE RSE OLS TGZ SEET EE A CODEC OICR Generate package gt make es cpack gt make amp amp make package ENEE ia Le CMake build system Castagnede C dric June 19th 2
6. ll phase not defined include lt stdio h gt VOILE QSL Message Nome ere luce renens VON CN EE EE ono printf Hello World n H Le CMake build system Castagnede Cedric June 19th 2012 18 CMAKE MINIMUM REQUIRED VERSION 5 6 PROJECT helloworld C INCLUDE CheckIncludeFile ENEE HAVE STDIO LF NOT HAVE STDIO MESSAGE FATAL ERROR EE EH ECHO o E Ee Be sek ENDIF INCLUDE CheckFunctionEx1sts Gigli Clg IU ING TIL SIL Sat S oie ig En HAVE PRINTF Pe NOt EVE PEINE MESSAGE FATAL ERROR Looking o SE A eebe eh ENDIF JENICO Bs EE Een ADDF OPDI EC Yi je DIB VUP DIET EC CRO Es CMake build system Castagn de C dric CMAKE MINIMUM REQUIRED VERSION 2 0 JUDD EAR es ao eee INSTALL TARGETS foo DESTINATION TID CHEE SNM EOU PRED als ON 2 0 ADD EXECUTABLE my helloworld main c TARGET LINK LIBRARIES my helloworld foo INSTALL TARGETS foo DESTINATION bin June 19th 2012 19 Test integration CMake build system Castagnede Cedric June 19th 2012 20 About CTest e CTest comes with CMake e l tcan be use without CMake e It allows to e automate updating form a repository e configuration and build e execute unit or regression tests e execute advanced tests coverage purify valgrind e Results can be submit to a CDash server d Le CMake build system Castagn de C dric June 19th 2012 21 Introduction to CTest e Modify CMake
7. tive build environment e determine available OS compiler features foo h libbar strndup Wall etc e name correctly the library so dylib dll e adaptability according user environment e auto configuration of the project e determine the availability and location of libraries commands 4 Le CMake build system Castagnede Cedric June 19th 2012 6 Features of a build system 2 e customize installation e cross compiling e give some information help e possibility to set information prefix libdir disable shared etc s have some target make all make install e launch tests e without installation link with generated library e after an installation link with installed library e give a report of the build 4 Le CMake build system Castagnede Cedric June 19th 2012 7 CMake build system CMake build system Castagn de C dric June 19th 2012 8 Introduction e Open source cross platform build system New BSD Licence e Develop by Kitware since 2001 e Using compiler independent method e Can be used with native build environments Eclipse Xcode Visual Studio e Give some extensions to locate libraries headers e Give some interfaces for generate a test suite and packaging e Notable applications using CMake KDE Blender LLVM OGRE H Lrar a CMake build system Castagnede C dric June 19th 2012 9 Get and install CMake e Get and install from web
8. usr local home toto my project e activate the verbosity of makefiles EE e produce shared or static library CMAKE SHARED LIBS OFF ON e etc H Le CMake build system Castagn de C dric June 19th 2012 14 A simple syntax 1 e Look like script language note a Jeune el done e variable SET VAR toto w list LIST KEYWORD list iostream e Command COMMAND ARG1 ARG2 e Control structure ITF S VAR FOREACH VAR VAL1 VAL2 ENDIF ENDFOREACH e Dynamic configuration CONDE U DART EE o ia aia SOME Sa H Le CMake build system Castagn de C dric June 19th 2012 15 e Library detection EE PATH path A simple syntax 2 GIERDEN CUIDA REQUIRED e Feature validation INCLUDE CheckCCompilerFlag CHECK C COMPILER FLAG flag HAVE FLAG INCLUDE CheckSourceCompiles Chine 6 O OUE CEE COMES eo VAR T CMake build system Castagn de C dric INCLUDE CheckFunctionEx1sts CRE CR UIC ALIEN Je Sion deta E HAVE FUNC INCLUDE CheckIncludeFile CCS JING IO Dl a IL LE header HAVE HEADER June 19th 2012 16 Exercise helloworld cmake 1 helloworld cmake CMakeLists jaca src txt H Le CMake build system Castagn de C dric June 19th 2012 17 Exercise helloworld cmake 2 include lt foo h gt The quickest way to compile the project PAP NOTES Meter O Feature test are not here PILLE MessAace EENEG insta
Download Pdf Manuals
Related Search
Related Contents
Catalogo Tifcom generato il inclination sensor 20~21ページ [PDFファイル/223KB] INFORME DE CERTIFICACIÓN 取扱説明書 V。ー このたびは弊社製品をお買い上げいただき、誠に Conduite de projets informatiques Samsung SF-650 fax machine WM-700の取扱説明書 Hanns.G HannsPad SN14T71 16GB Black, Silver tablet Copyright © All rights reserved.
Failed to retrieve file