mirror of
https://github.com/PixarAnimationStudios/OpenSubdiv
synced 2024-11-08 13:30:04 +00:00
Clean up the CMakeLists.txt in the far tutorials
Most of the tutorials are built and installed the same way so provide a common _add_far_tutorial macro.
This commit is contained in:
parent
9c41e8610a
commit
134ee33255
@ -21,6 +21,19 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
macro(_add_far_tutorial NAME)
|
||||
|
||||
_add_executable(${NAME} "tutorials/far"
|
||||
${ARGN}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS ${NAME} DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
endmacro()
|
||||
|
||||
|
||||
set(TUTORIALS
|
||||
tutorial_0
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_0
|
||||
far_tutorial_0.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_0 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_0 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_1
|
||||
far_tutorial_1.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_1 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_1 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_10
|
||||
far_tutorial_10.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_10 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_10 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_2
|
||||
far_tutorial_2.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_2 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_2 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_3
|
||||
far_tutorial_3.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_3 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_3 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_4
|
||||
far_tutorial_4.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_4 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_4 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_5
|
||||
far_tutorial_5.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_5 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_5 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_6
|
||||
far_tutorial_6.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_6 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_6 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_7
|
||||
far_tutorial_7.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_7 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_7 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,17 +21,7 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_8
|
||||
far_tutorial_8.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_8 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_8 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
@ -21,18 +21,8 @@
|
||||
# KIND, either express or implied. See the Apache License for the specific
|
||||
# language governing permissions and limitations under the Apache License.
|
||||
#
|
||||
|
||||
set(SOURCE_FILES
|
||||
_add_far_tutorial(
|
||||
far_tutorial_9
|
||||
far_tutorial_9.cpp
|
||||
)
|
||||
|
||||
_add_executable(far_tutorial_9 "tutorials/far"
|
||||
${SOURCE_FILES}
|
||||
$<TARGET_OBJECTS:sdc_obj>
|
||||
$<TARGET_OBJECTS:vtr_obj>
|
||||
$<TARGET_OBJECTS:far_obj>
|
||||
$<TARGET_OBJECTS:regression_common_obj>
|
||||
)
|
||||
|
||||
install(TARGETS far_tutorial_9 DESTINATION "${CMAKE_BINDIR_BASE}/tutorials")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user