Feature-Request: PROJECT_NAME as target-property and directory-property
Hi,
having not found anything similar (did I miss it?), I propose the following feature:
- a property
PROJECT_NAME
, attached to each target and source directory (if multipleproject()
calls in CMakeLists.txt, default the directory-property to either first or last one; or create a list)
I need this, in order to do
set_propery(DIRECTORY ${PROJECT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT ${targ}
# \
# PROJECT_SOURCE_DIR **not** usable, as I call the above from the end
# of the toplevel CMakeLists.txt
# and recurse through all directories and targets via properties
#
# Hence I need to figure out the PROJECT_NAME by
# querying that property from a target or property !!!!!!!!
#
#
# I want this:
get_property(projname TARGET ${targ} PROPERTY PROJECT_NAME) # feature request!
set_propery(DIRECTORY ${projname} PROPERTY VS_STARTUP_PROJECT ${targ}