-
First, install the cpptools extension in studio code
-
Then add the include paths in the c_cpp_properties.json file.
If a small light bulb icon (💡) appears near the include statements on any of your source file, just click it in order to access the c_c_pp_properties.json file.
If there's no 💡 icon, then in the project directory create a hidden folder called vscode:
mkdir .vscode
Then inside this folder create the c_c_pp_properties.json.
I uploaded a sample file in this gist, so you can use it as a template.
The paths are those (obviously will change depending on where you downloaded openframeworks and on your XCode installation):
"/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/include/" "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/include/c++/4.2.1" "~/Documents/Code/of_v0.9.8_osx_release/libs" "~/Documents/Code/of_v0.9.8_osx_release/addons"
-
Create a new project using the project generator
-
Modify the ofApp source code as you need
-
Finally, run the
make
command in your working folder (above the src dir)
Last active
August 17, 2023 02:59
-
-
Save vvzen/6aab1427bb9d6a89556a00c39d4ff009 to your computer and use it in GitHub Desktop.
A quick reminder on how to use openframeworks without XCode (macOS)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"configurations": [ | |
{ | |
"name": "Mac", | |
"includePath": [ | |
"/usr/include", | |
"/usr/local/include", | |
"/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/include/", | |
"/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk/usr/include/c++/4.2.1", | |
"~/Documents/Code/of_v0.9.8_osx_release/libs", | |
"~/Documents/Code/of_v0.9.8_osx_release/addons" | |
], | |
"browse": { | |
"limitSymbolsToIncludedHeaders": true, | |
"databaseFilename": "" | |
} | |
}, | |
{ | |
"name": "Linux", | |
"includePath": [ | |
"/usr/include", | |
"/usr/local/include" | |
], | |
"browse": { | |
"limitSymbolsToIncludedHeaders": true, | |
"databaseFilename": "" | |
} | |
}, | |
{ | |
"name": "Win32", | |
"includePath": [ | |
"C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/include/*" | |
], | |
"browse": { | |
"limitSymbolsToIncludedHeaders": true, | |
"databaseFilename": "" | |
} | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment