Skip to content

Commit

Permalink
Add Visual Studio folders using source_group() and add headers to them (
Browse files Browse the repository at this point in the history
mmp#206)

Without that, the Visual Studio solution does not show headers, and does group all source files from all sub-directories into on big mess.
  • Loading branch information
SRombauts authored and mmp committed Nov 8, 2018
1 parent 5414dc9 commit 3a735dd
Showing 1 changed file with 25 additions and 12 deletions.
37 changes: 25 additions & 12 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -450,23 +450,36 @@ SET ( PBRT_CORE_HEADERS
)

FILE ( GLOB PBRT_SOURCE
src/ext/*.c
src/ext/*.cpp
src/accelerators/*.cpp
src/cameras/*.cpp
src/filters/*.cpp
src/integrators/*.cpp
src/lights/*.cpp
src/materials/*.cpp
src/samplers/*.cpp
src/shapes/*.cpp
src/textures/*.cpp
src/media/*.cpp
src/ext/*
src/accelerators/*
src/cameras/*
src/filters/*
src/integrators/*
src/lights/*
src/materials/*
src/samplers/*
src/shapes/*
src/textures/*
src/media/*
)

INCLUDE_DIRECTORIES ( src )
INCLUDE_DIRECTORIES ( src/core )

# Visual Studio source folders
SOURCE_GROUP (core REGULAR_EXPRESSION src/core/.*)
SOURCE_GROUP (ext REGULAR_EXPRESSION src/ext/.*)
SOURCE_GROUP (accelerators REGULAR_EXPRESSION src/accelerators/.*)
SOURCE_GROUP (cameras REGULAR_EXPRESSION src/cameras/.*)
SOURCE_GROUP (filters REGULAR_EXPRESSION src/filters/.*)
SOURCE_GROUP (integrators REGULAR_EXPRESSION src/integrators/.*)
SOURCE_GROUP (lights REGULAR_EXPRESSION src/lights/.*)
SOURCE_GROUP (materials REGULAR_EXPRESSION src/materials/.*)
SOURCE_GROUP (samplers REGULAR_EXPRESSION src/samplers/.*)
SOURCE_GROUP (shapes REGULAR_EXPRESSION src/shapes/.*)
SOURCE_GROUP (textures REGULAR_EXPRESSION src/textures/.*)
SOURCE_GROUP (media REGULAR_EXPRESSION src/media/.*)

###########################################################################
# pbrt libraries and executables

Expand Down

0 comments on commit 3a735dd

Please sign in to comment.