Execution failed for task ':deployFrcCppRoborio' Error

I have been messing with our robot and have been getting this error. It was initially a gradleRio error that I fixed. But now I get this error. Help would be very greatly appreciated.

Task :deployFrcCppRoborio FAILED

Task :deployFrcCppLibrariesRoborio
22 file(s) are up-to-date and were not deployed
-C-> chmod -R 777 “/usr/local/frc/third-party/lib” || true; chown -R lvuser:ni “/usr/local/frc/third-party/lib” @ /usr/local/frc/third-party/lib
-C-> ldconfig @ /usr/local/frc/third-party/lib

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ‘:deployFrcCppRoborio’.

FRCNativeArtifact[frcCpp] Link Task has no output files: task ‘:linkFrcUserProgramReleaseExecutable’

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

  • Get more help at https://help.gradle.org

5 actionable tasks: 3 executed, 2 up-to-date
The terminal process terminated with exit code: 1

This is saying nothing was actually compiled, so it found no program to actually deploy. Are you trying just a base template, or did you attempt to change anything in the build. If you attempted to move files, or don’t have any cpp files at all, that issue will occur. If you can post your build.gradle file, or a link to your entire project that would help.

Here is the build.gradle

plugins {
id “cpp”
id “google-test-test-suite”
id “edu.wpi.first.GradleRIO” version “2019.4.1”

// Define my targets (RoboRIO) and artifacts (deployable files)
// This is added by GradleRIO’s backing project EmbeddedTools.
deploy {
targets {
roboRIO(“roborio”) {
// Team number is loaded either from the .wpilib/wpilib_preferences.json
// or from command line. If not found an exception will be thrown.
// You can use getTeamOrDefault(team) instead of getTeamNumber if you
// want to store a team number in this file.
team = frc.getTeamNumber()
artifacts {
frcNativeArtifact(‘frcCpp’) {
targets << “roborio”
component = ‘frcUserProgram’
// Debug can be overridden by command line, for use with VSCode
debug = frc.getDebugOrDefault(false)
// Built in artifact to deploy arbitrary files to the roboRIO.
fileTreeArtifact(‘frcStaticFileDeploy’) {
// The directory below is the local directory to deploy
files = fileTree(dir: ‘src/main/deploy’)
// Deploy to RoboRIO target, into /home/lvuser/deploy
targets << “roborio”
directory = ‘/home/lvuser/deploy’

// Set this to true to include the src folder in the include directories passed
// to the compiler. Some eclipse project imports depend on this behavior.
// We recommend leaving this disabled if possible. Note for eclipse project
// imports this is enabled by default. For new projects, its disabled
def includeSrcInIncludeRoot = false

// Set this to true to enable desktop support.
def includeDesktopSupport = false

model {
components {
frcUserProgram(NativeExecutableSpec) {
targetPlatform wpi.platforms.roborio
if (includeDesktopSupport) {
targetPlatform wpi.platforms.desktop

        sources.cpp {
            source {
                srcDir 'src/main/cpp'
                include '**/*.cpp', '**/*.cc'
            exportedHeaders {
                srcDir 'src/main/include'
                if (includeSrcInIncludeRoot) {
                    srcDir 'src/main/cpp'

        // Defining my dependencies. In this case, WPILib (+ friends), and vendor libraries.
        useLibrary(it, "wpilib")
testSuites {
    frcUserProgramTest(GoogleTestTestSuiteSpec) {
        testing $.components.frcUserProgram

        sources.cpp {
            source {
                srcDir 'src/test/cpp'
                include '**/*.cpp'

        useLibrary(it, "wpilib", "googletest")


Ok. So are all your source files in src/main/cpp. If your source files are in another folder, or theyre c files, not c++, that issue will occur.