コード例 #1
0
def check_platform():
    rosconfig_exists = os.path.exists(core.rosconfig_cmake())
    if rosconfig_exists:
        print "-- Found rosconfig.cmake."
        print "  -- Setting the install prefix to ${TOOLCHAIN_INSTALL_PREFIX}"
        prefix.set_install_prefix("${TOOLCHAIN_INSTALL_PREFIX}")
        print "  -- Confirm that it is compatible with the current toolchain."
    else:
        print "-- No rosconfig.cmake, generating a default (vanilla) configuration."
        platform.select_default()
コード例 #2
0
def check_install_prefix():
    ''' 
    Runs a quick check to see if a toolchain is installed, and if so, 
    configures the install prefix to match the toolchain's install root.
    '''
    if core.is_rostoolchain_cmake():
        print "-- Found rostoolchain configuration (rostoolchain.cmake)."
        print "  -- Setting the install prefix to ${TOOLCHAIN_INSTALL_PREFIX}"
        prefix.set_install_prefix("${TOOLCHAIN_INSTALL_PREFIX}")
        print "  -- Confirm that it is compatible with the current toolchain."
        print "  -- Or modify it as you wish with 'rosprefix'."
    else:
        print "-- No rostoolchain found (rostoolchain.cmake)."
        print "  -- Setting the install prefix to /usr/local."