Add opensubdiv/version.cpp

This empty cpp file is added to address some cmake dependency resolution issues
with XCode project-based build generation.

I may add some functionality to version.cpp in the future

Thanks stopiccot for investigating the issue and doing most of the leg-work.

fixes #356
This commit is contained in:
manuelk 2014-11-25 12:37:03 -08:00
parent c2e8148efc
commit a9c32d6705
3 changed files with 45 additions and 0 deletions

View File

@ -139,6 +139,7 @@ if (NOT NO_LIB)
# Build static libs ------------------------------------
add_library(osd_static_cpu
STATIC
version.cpp
$<TARGET_OBJECTS:sdc_obj>
$<TARGET_OBJECTS:vtr_obj>
$<TARGET_OBJECTS:far_obj>
@ -156,6 +157,7 @@ if (NOT NO_LIB)
# the target then adds the other obj dependencies and include files
_add_possibly_cuda_library(osd_static_gpu
STATIC
version.cpp
$<TARGET_OBJECTS:osd_gpu_obj>
${CUDA_KERNEL_FILES}
)
@ -176,6 +178,7 @@ if (NOT NO_LIB)
#---------------------------------------------------
add_library(osd_dynamic_cpu
SHARED
version.cpp
$<TARGET_OBJECTS:sdc_obj>
$<TARGET_OBJECTS:vtr_obj>
$<TARGET_OBJECTS:far_obj>
@ -206,6 +209,7 @@ if (NOT NO_LIB)
#---------------------------------------------------
_add_possibly_cuda_library(osd_dynamic_gpu
SHARED
version.cpp
$<TARGET_OBJECTS:osd_gpu_obj>
${CUDA_KERNEL_FILES}
)

32
opensubdiv/version.cpp Normal file
View File

@ -0,0 +1,32 @@
//
// Copyright 2013 Pixar
//
// Licensed under the Apache License, Version 2.0 (the "Apache License")
// with the following modification; you may not use this file except in
// compliance with the Apache License and the following modification to it:
// Section 6. Trademarks. is deleted and replaced with:
//
// 6. Trademarks. This License does not grant permission to use the trade
// names, trademarks, service marks, or product names of the Licensor
// and its affiliates, except as required to comply with Section 4(c) of
// the License and to reproduce the content of the NOTICE file.
//
// You may obtain a copy of the Apache License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the Apache License with the above modification is
// distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
// KIND, either express or implied. See the Apache License for the specific
// language governing permissions and limitations under the Apache License.
//
#include "./version.h"
namespace OpenSubdiv {
namespace OPENSUBDIV_VERSION {
} // end namespace OPENSUBDIV_VERSION
} // end namespace OpenSubdiv

View File

@ -27,4 +27,13 @@
#define OPENSUBDIV_VERSION v3_0_0_alpha
namespace OpenSubdiv {
namespace OPENSUBDIV_VERSION {
} // end namespace OPENSUBDIV_VERSION
using namespace OPENSUBDIV_VERSION;
} // end namespace OpenSubdiv
#endif /* OPENSUBDIV_VERSION_H */