summaryrefslogtreecommitdiffstats
path: root/cmake/common.cmake
AgeCommit message (Collapse)AuthorFilesLines
2018-10-18Minor fixesRomain Forlot1-1/+1
- CMake module name has changed so the warning message needs to be updated - Reset the shell color at the end of the warning message. - Wrong variable used to add target's property - Complete path to cmake script file, there is a difference between cmake module and git submodule version Change-Id: Ia730773cbefef485982da03dbf1281b29485ea51 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-10-05Adding warning message to migrate on CMake moduleRomain Forlot1-0/+2
Add a warning that no update will further be delivered and that the developper should migrate to cmake module. With instructions on how to do so. Bugs-AGL: SPEC-1682 Change-Id: I0158b729f7cf1c9b3b7ab639f42bc52028d7835c Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-09-20common.cmake: fixed erroneous search path for os-releaseguppy_6.90.0guppy/6.90.06.90.0Thierry Bultel1-1/+1
Change-Id: I20eb2c342e33d838b9f8c80b7ec93c32794b4eeb Signed-off-by: Thierry Bultel <thierry.bultel@iot.bzh>
2018-07-09Use CACHE variable for other common CMAKE variableRomain Forlot1-0/+1
This is done to be able to overwite from CLI those variables. CMAKE_INSTALL_PREFIX is a special case since it is set by default to '/usr/local' at CMake invocation. So overwriting by CLI is fine but set it up using config.cmake file not. So since CMake v3.7 there is a variable to know if this variable has been set by default or not. Change-Id: I60c5161fa9a4134d100ef709d0966d599871ad44 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-07-05Fix: SYSROOT location detection... Wrong test.Romain Forlot1-1/+1
Change-Id: I8c783cf3bc966b2bec54cab98de97f1e47d3b54c Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-06-27Disable the in-tree build method.Romain Forlot1-0/+2
In-tree build could lead to problems and is not recommended because only one-setup, generated files spread over the project tree, clean is a pain in the ass and it just trash completely your git repo... Bug-AGL: SPEC-1534 Change-Id: I68cfd0e03933d87db7f6b2bdb88f22ddd94c2b98 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-06-27Detect Yocto as OS distributionRomain Forlot1-1/+2
When you are in a Yocto Environment there isn't os-release file, so if the Yocto env is detected then position manually the OSRELEASE variable to yocto-build. Change-Id: I10029664100bb73aa74eaa85c1a4295c4ab65428 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-05-16Improve OS detectionRomain Forlot1-4/+11
Every distribution name detected in ID_LIKE field could be used. Change-Id: I767b1bb20521248b30269955ce6a15912a62df33 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2018-05-14Fix: OS detectionRomain Forlot1-1/+1
Change-Id: Idcf5e85bfeab4edf1dbf52b6a0e3470ad350f939 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-11-17Check version between app-templates and project.Romain Forlot1-0/+1
PROJECT_VERSION could be detected if project is located in AGL gerrit repo or with personal tags when in personal repository This version is checked against app-templates version which is aligned on AGL tags. A warning is displayed if app-templates version is outdated related to project_version. Also a "dirty" flag is appended to the project version if git repo isn't in sync with its remote counterpart. Then you could know if see an installed widget on a target that got that "-dirty" flag appended to the version that this widget include code that could not be merged in the git repository. Bug-AGL: SPEC-951 Change-Id: I99687560d19d746c887fc7a095e71407bda34325 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-10-04Include ExternalProject CMake module by defaultRomain Forlot1-0/+3
Change-Id: Icf3929e6f2b0c28d3281ee451527ec1085ac9c7f Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-29Fix: wrong OS detection when SDK env or YoctoRomain Forlot1-0/+11
Change-Id: Iece230f0708129ea5980c61dae2d2cb66d32e7eb Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-28Dirty fix to handle distro specific packages depsRomain Forlot1-11/+27
Could include first distro specific file to be able to modify variable from config.cmake and then process classic submodule cmake files. Change-Id: Id5dad2504d44c86cb165ad56f5314e9c0c545f0b Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-23Fix: wrong variable detectionRomain Forlot1-1/+1
Change-Id: Idc736c60f51e20640476202996121eefef8b8210 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-23OS detection to fallback instead of additionRomain Forlot1-1/+5
Instead of include a default cmake file in addition of the others, use it as fallback if any other cmake file doesn't match Change-Id: Ib46e0e64a5f485dcad4e41f092936484da83b7f4 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-21Add macros to make a 2nd pass on required moduleRomain Forlot1-1/+0
Useful when adding module dependant of distro as they do not named their packages the same way... Change-Id: I0422ce4cdad48f9e815d24510376ad11941d5e3d Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-21Better OS detection and inclusion per distributionRomain Forlot1-2/+10
Change-Id: I6f479353df990eb2ff9030b7427d48bb72f0416f Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-17Added per project custom template dirRomain Forlot1-0/+1
Change-Id: I5175b45a0d493724492157af2d32f4e51a04665f Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-08-16Personal files inclusion now by projects.Romain Forlot1-2/+2
Depending on file name you can include some files from your home or system by project or globally Change-Id: I1fef678073977633576a21893065e681b286646c Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-07-21Project cmake file have precedence on home & sysRomain Forlot1-1/+1
Change-Id: Ied2c6e3c7f378b27a84229999b84dfc649a4e657 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-07-10Fix: shared library files not found by gdbRomain Forlot1-0/+1
Old behavior assume a PATH that do not exists using XDS-server this patch intends to make a list of bindings using a regex, as GDB interprets the argument. Change-Id: I67caa1853be67813e8de02cdbb34f107f1e1676c Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-07-05Fix: wrong macro nameRomain Forlot1-2/+2
Change-Id: Ia0af4453536509606f55a9557eff73a4d44e56ec Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-07-04Change location for custom CMake files and scriptsRomain Forlot1-2/+5
Use one additionnal level to put all app-templates related files in one directory. Change-Id: Iec297d0070d8d47a4ce9e351bedb3ec45f691af4 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-28change path etc/config.cmake to conf.d/cmake/config.cmakeRonan Le Martret1-2/+2
Change-Id: I98d51ce911c51ced28760c53420ffdf474fe48f1 Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2017-06-27Only 1 include in root CMake and no macro to callRomain Forlot1-13/+8
Added a variable to specify pattern to search CMakeLists.txt over directories and include common.cmake from config.cmake file. Now it isn't needed to call any macro to configure the project. Change-Id: I0c0eecc684db4f8ee1055d84205ad457a6fde179 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-27Correct precedence over included filesRomain Forlot1-1/+1
Change-Id: Ifc6f2bf72ea5bc9f497745cc65041f047e8b86bd Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-27Recursive include cmake file systemn home, projectRomain Forlot1-99/+11
Can now include any cmake file named with the template name [0-9][0-9]-*.cmake Change-Id: If6caf4e254691bb7b9b0e4e0b7adf9f19560ff25 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-27Add wrapper to 4 most commons macrosRomain Forlot1-0/+15
1 macros to call in the right orders 4 following macros: - project_subdirs_add - project_targets_populate - project_package_build - project_closing_msg Could take 1 argument passed to project_subdirs_add Change-Id: I4ae7e24f1a865413156c5c70b77098c3a20349b0 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-26Check Kernel version against SDK env or Host env.Romain Forlot1-5/+19
This use Kernel header version.h to determine which is the current kernel version use to develop the project Change-Id: I0a654a5a0fc89543fa3d855c7adc6d319dd0b53c Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-26Split common files into specialized cmake files.Romain Forlot1-467/+7
Change-Id: I5c920f78c583a6a4eaeb53146413c35c640b4bbb Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-21Configure file at build time with separated targetRomain Forlot1-67/+100
Change-Id: I0464897b830e926bb173c9b80ef7682ff47ecb5b Signed-off-by: Romain Forlot <romain.forlot@iot.bzh> Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2017-06-20Update packaging creationRonan Le Martret1-22/+120
* update rpm creation * add deb packaging Change-Id: Idc1623b7b0ca72d4842e59f9495fc26c487ef008 Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2017-06-15Fix: remove old bug about overwriten variables.Romain Forlot1-2/+0
Change-Id: I81a6d9f68c04ad309ac023a1aa2257b83393bcb9 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-15Fix gdb debugging and add widget install on targetSebastien Douheret1-8/+27
Change-Id: I67698bbbfa626e55cbe382afd7e9c5eb699f6149 Signed-off-by: Sebastien Douheret <sebastien.douheret@iot.bzh>
2017-06-13Merge "Replace LIBRARIES by LDFLAGS for pkgconfig dep"Romain Forlot1-1/+1
2017-06-12Fix:WIDGET_ENTRY_POINT variable always overwrittenRomain Forlot1-4/+6
Change-Id: I429676174add205d60b9cd0d03f091f2533a5182 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-12Fix wrong path to submodule files.Romain Forlot1-2/+0
Change-Id: Ic28656d1e662b639ea84d052dbf48876c7ed7737 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-12Replace LIBRARIES by LDFLAGS for pkgconfig depRonan Le Martret1-1/+1
XXX_LIBRARIES provide the lib name, LDFLAGS lib name and path. Change-Id: Iad84a450e2a0876e8c9d284408a43f472e1f275f Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2017-06-12Merge "Set default value for APP_TEMPLATES_DIR and WIDGET_ENTRY_POINT"Jan-Simon Moeller1-5/+12
2017-06-09Don't ship config.xml to packaging dir. UselessRomain Forlot1-1/+0
Change-Id: I1d5daebf7870e372d615c4f39e2a538a6590d189 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-09Set default value for APP_TEMPLATES_DIR and WIDGET_ENTRY_POINTSebastien Douheret1-5/+12
Change-Id: I275373636bfa4e33e0c82ff934971ee17501bfe1 Signed-off-by: Sebastien Douheret <sebastien.douheret@iot.bzh>
2017-06-09Remove spec file from package tree.Romain Forlot1-1/+1
Change-Id: I1cca6118dc07efe15f408b222980fecf6ad0d125 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-09Added a target to build an archive from git repoRomain Forlot1-1/+8
Change-Id: If6f491f7bf8e3e7a29b9c9db369126dc550318c3 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-09Fix: cli CMAKE_INSTALL_PREFIX variable ignoredRomain Forlot1-1/+1
Don't overwrite CMAKE_INSTALL_PREFIX Change-Id: Ie4b0a6dde2b59fee6704369b6fe66a1390c4a092 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-06-09cmake: add WIDGET_CONFIG_TEMPLATE setting to specify location for config.xml.inStephane Desneux1-4/+10
Change-Id: I285196388c12145b6b049af692a7a67c03aaba24 Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
2017-06-08common.cmake: fix icon copy and final name in packageStephane Desneux1-1/+2
Change-Id: I6791a0e0de9e8f3d3b540550f9dfe9c06821f4ae Signed-off-by: Stephane Desneux <stephane.desneux@iot.bzh>
2017-06-07fix local rpm buildRonan Le Martret1-1/+2
Signed-off-by: Ronan Le Martret <ronan.lemartret@iot.bzh>
2017-05-29DescriptionRomain Forlot1-2/+2
Change-Id: I81f684b829d612fb58330cf0aeaca5e1097e3b4b Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-05-29Trick to always execute popule http and data dirRomain Forlot1-4/+6
This will fake cmake to make it believe that the output produced by custom_command never exists so it have to re execute the command... Change-Id: I3836510d5c522b8f23991669eb07b08bf17aba5f Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
2017-05-29FormatRomain Forlot1-7/+7
Change-Id: I5197065ea620cee4accca7e097df9a49b796c671 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>