Skip to content

Commit

Permalink
SGL env setup (#34)
Browse files Browse the repository at this point in the history
* SGL env setup

* Remove language version from pre-commit

* Remove auto-install of prerequisits from setup
Fix clang path
Add note to docs about python build requirements

* Fix launch.json
  • Loading branch information
ccummingsNV authored Jul 11, 2024
1 parent 6fa4f1a commit b139313
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 73 deletions.
1 change: 0 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ repos:
rev: 24.4.2
hooks:
- id: black
language_version: python3.9
exclude: |
(?x)^(
.*\.ipynb|
Expand Down
87 changes: 17 additions & 70 deletions .vscode-default/launch.json
Original file line number Diff line number Diff line change
@@ -1,89 +1,36 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
//
// Note: These launch configurations rely on the ms-vscode.cmake-tools extension
// to provide ${command:cmake.launchTargetPath} and ${command:cmake.launchTargetDirectory}.
//
"version": "0.2.0",
"configurations": [

{
// Launch configuration for currently selected target.
"name": "Selected CMake Target",
"type": "cppvsdbg",
"name": "Python C++ Debugger Windows",
"type": "pythoncpp",
"request": "launch",
"program": "${command:cmake.launchTargetPath}",
"args": [],
"stopAtEntry": false,
"cwd": "${command:cmake.launchTargetDirectory}",
"environment": [
{
"name": "FALCOR_DEVMODE",
"value": "1"
}
],
"visualizerFile": "${workspaceFolder}/Source/Falcor/Falcor.natvis"
"pythonConfig": "default",
"cppConfig": "default (win) Attach"
},
{
// Launch configuration for Mogwai.
"name": "Mogwai",
"type": "cppvsdbg",
"name": "Python C++ Debugger GDB",
"type": "pythoncpp",
"request": "launch",
"windows": {
"program": "${command:cmake.launchTargetDirectory}/Mogwai.exe"
},
"args": [],
"stopAtEntry": false,
"cwd": "${command:cmake.launchTargetDirectory}",
"environment": [
{
"name": "FALCOR_DEVMODE",
"value": "1"
}
],
"visualizerFile": "${workspaceFolder}/Source/Falcor/Falcor.natvis"
"pythonConfig": "default",
"cppConfig": "default (gdb) Attach"
},
{
// Launch configuration for FalcorTest.
"name": "FalcorTest",
"type": "cppvsdbg",
"name": "Python Debugger: Current File",
"type": "debugpy",
"request": "launch",
"windows": {
"program": "${command:cmake.launchTargetDirectory}/FalcorTest.exe"
},
"args": [],
"stopAtEntry": false,
"cwd": "${command:cmake.launchTargetDirectory}",
"environment": [
{
"name": "FALCOR_DEVMODE",
"value": "1"
}
],
"visualizerFile": "${workspaceFolder}/Source/Falcor/Falcor.natvis"
"program": "${file}",
"console": "integratedTerminal"
},
{
// Launch configuration for Python example.
"name": "Python Example",
"name": "Selected CMake Target",
"type": "cppvsdbg",
"request": "launch",
"windows": {
"program": "${config:python.defaultInterpreterPath}"
},
"args": [
"${workspaceFolder}/scripts/internal/python/simple.py"
],
"program": "${command:cmake.launchTargetPath}",
"args": [],
"stopAtEntry": false,
"cwd": "${command:cmake.launchTargetDirectory}",
"environment": [
{
"name": "FALCOR_DEVMODE",
"value": "1"
}
],
"internalConsoleOptions": "openOnSessionStart",
"visualizerFile": "${workspaceFolder}/Source/Falcor/Falcor.natvis"
"cwd": "${command:cmake.launchTargetDirectory}"
}
]
}
9 changes: 7 additions & 2 deletions .vscode-default/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
},
"cmake.configureOnEdit": false,
"cmake.options.statusBarVisibility": "visible",
"C_Cpp.clang_format_path": "${workspaceFolder}/tools/.packman/clang-format/clang-format",
"slang.format.clangFormatLocation": "${workspaceFolder}/tools/.packman/clang-format/clang-format"
"C_Cpp.clang_format_path": "${workspaceFolder}/tools/host/clang-format/clang-format",
"slang.format.clangFormatLocation": "${workspaceFolder}/tools/host/clang-format/clang-format",
"cmake.configureOnOpen": false,
"python.testing.pytestEnabled": true,
"python.testing.pytestArgs": [
"./src/sgl"
]
}
3 changes: 3 additions & 0 deletions docs/src/developer_guide/compiling.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ To make it easy to build ``sgl`` reliably, an additional setup step is required:

.. code-block:: bash
# Install Python build prerequisites
pip install -r tools/buildrequirements.txt
# On Windows
setup.bat
Expand Down
1 change: 1 addition & 0 deletions examples/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
numpy
3 changes: 3 additions & 0 deletions tools/buildrequirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
typing_extensions
pre-commit
pytest

0 comments on commit b139313

Please sign in to comment.