Quantcast
Channel: Active questions tagged visual-studio-code - Stack Overflow
Viewing all articles
Browse latest Browse all 99173

Failed to launch external program in VSCode with pkg-config

$
0
0

I have created a simple main.cpp. I have also created a tasks.json under .vscode folder which is as follow.

{
  // See https://go.microsoft.com/fwlink/?LinkId=733558
  // for the documentation about the tasks.json format
  "version": "0.1.0",
  "command": "g++ $(pkg-config --cflags --libs opencv)",
  "isShellCommand": true,
  "args": ["main.cpp"],
  "showOutput": "always"
}

g++ $(pkg-config --cflags --libs opencv) main.cpp is running properly in terminal. However, it's not working in the task runner in vscode. The error message is

Failed to launch external program g++ $(pkg-config --cflags --libs opencv)

Any suggestion for that ?


Viewing all articles
Browse latest Browse all 99173

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>