From ee95971a3265aabe4233f8efeb4df282962e1acc Mon Sep 17 00:00:00 2001 From: NADAL Jean-Baptiste Date: Tue, 24 Apr 2018 22:35:24 +0200 Subject: [PATCH] update project configure (add compiation and debug of rest plugin) --- .vscode/launch.json | 29 ++++++++++++++++++++++++++++- .vscode/tasks.json | 34 +++++++++++++++++++++++++++++++++- 2 files changed, 61 insertions(+), 2 deletions(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index 7a5168c7..46ce9e26 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -27,6 +27,33 @@ "ignoreFailures": true } ] - } + }, + { + "name": "(gdb) uhttp", + "type": "cppdbg", + "request": "launch", + "program": "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/local/bin/uhttpd", + "args": ["-p", "34000", + "-f", + "-h", "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/local/share/restd/", + "-U", "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/local/configs/restd/"], + "stopAtEntry": false, + "cwd": "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/", + "environment": [ + { + "name": "LD_LIBRARY_PATH", + "value": "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/lib:${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/local/lib:${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/local/bin/plugins" + } + ], + "externalConsole": true, + "MIMode": "gdb", + "setupCommands": [ + { + "description": "Enable pretty-printing for gdb", + "text": "-enable-pretty-printing", + "ignoreFailures": true + } + ] + } ] } \ No newline at end of file diff --git a/.vscode/tasks.json b/.vscode/tasks.json index 5cd9a514..862efefa 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -85,5 +85,37 @@ "$gcc" ] }, + { + "label": "X86_64 - cmake - uhttpd-rest-api", + "type": "shell", + "command": "mkdir -p ${BUILD_DIR}/uhttpd-rest-api && cd ${BUILD_DIR}/uhttpd-rest-api && cmake -DMODULE_PATH=${workspaceRoot}/bsp/cmake-modules -DworkspaceRoot=${workspaceRoot} -DCMAKE_BUILD_TYPE=Debug -DCMAKE_TOOLCHAIN_FILE=${workspaceRoot}/bsp/cmake-modules/toolchain-buildroot.cmake -DCMAKE_INSTALL_PREFIX=${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/staging/usr/ ${workspaceRoot}/src/plugins/uhttpd/uhttpd-rest-api/builders/cmake", + "group": "build", + "options": { + "env": { + "BUILD_DIR": "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/build/" + } + }, + "presentation": { + "echo": true, + "reveal": "always" + }, + "problemMatcher": [] + }, + { + "label": "X86_64 - make - uhttpd-rest-api", + "options": { + "cwd": "${workspaceRoot}/_builds/x86_64_domo-debug/buildroot/build/uhttpd-rest-api", + }, + "type": "shell", + "command": "make install", + "group": "build", + "presentation": { + "echo": true, + "reveal": "always" + }, + "problemMatcher": [ + "$gcc" + ] + } ] -} \ No newline at end of file +}