mirror of https://github.com/AxioDL/metaforce.git
integrated libBoo submodule
This commit is contained in:
parent
1b3d5e1d3c
commit
d17f2a5e78
|
@ -7,3 +7,6 @@
|
||||||
[submodule "MathLib"]
|
[submodule "MathLib"]
|
||||||
path = MathLib
|
path = MathLib
|
||||||
url = https://github.com/RetroView/MathLib.git
|
url = https://github.com/RetroView/MathLib.git
|
||||||
|
[submodule "libBoo"]
|
||||||
|
path = libBoo
|
||||||
|
url = https://github.com/RetroView/libBoo.git
|
||||||
|
|
|
@ -10,6 +10,8 @@ else()
|
||||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wno-multichar -fno-exceptions")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wno-multichar -fno-exceptions")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
add_subdirectory(libBoo)
|
||||||
|
|
||||||
set(HECL_SUBPROJECT TRUE)
|
set(HECL_SUBPROJECT TRUE)
|
||||||
set(HECL_DATASPEC_DECLS
|
set(HECL_DATASPEC_DECLS
|
||||||
"/* RetroCommon specs */
|
"/* RetroCommon specs */
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
add_subdirectory(MP3)
|
|
||||||
add_subdirectory(MP2)
|
|
||||||
add_subdirectory(MP1)
|
|
||||||
add_subdirectory(Common)
|
add_subdirectory(Common)
|
||||||
|
add_subdirectory(MP1)
|
||||||
|
add_subdirectory(MP2)
|
||||||
|
add_subdirectory(MP3)
|
||||||
|
|
|
@ -30,15 +30,15 @@ public:
|
||||||
{++ReferenceCount();}
|
{++ReferenceCount();}
|
||||||
template<typename U = T>
|
template<typename U = T>
|
||||||
TOneStatic(typename std::enable_if<std::is_default_constructible<U>::value>::type* = 0)
|
TOneStatic(typename std::enable_if<std::is_default_constructible<U>::value>::type* = 0)
|
||||||
{++ReferenceCount(); new (GetAllocSpace()) T();}
|
{++ReferenceCount(); new (m_allocspace) T();}
|
||||||
|
|
||||||
template<typename... Args> TOneStatic(Args&&... args)
|
template<typename... Args> TOneStatic(Args&&... args)
|
||||||
{++ReferenceCount(); new (GetAllocSpace()) T(std::forward<Args>(args)...);}
|
{++ReferenceCount(); new (m_allocspace) T(std::forward<Args>(args)...);}
|
||||||
|
|
||||||
~TOneStatic() {--ReferenceCount();}
|
~TOneStatic() {--ReferenceCount();}
|
||||||
|
|
||||||
template<typename... Args> void reset(Args&&... args)
|
template<typename... Args> void reset(Args&&... args)
|
||||||
{new (GetAllocSpace()) T(std::forward<Args>(args)...);}
|
{new (m_allocspace) T(std::forward<Args>(args)...);}
|
||||||
};
|
};
|
||||||
template<class T> u8 TOneStatic<T>::m_allocspace[sizeof(T)];
|
template<class T> u8 TOneStatic<T>::m_allocspace[sizeof(T)];
|
||||||
template<class T> u32 TOneStatic<T>::m_refCount;
|
template<class T> u32 TOneStatic<T>::m_refCount;
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
Subproject commit 395e39d63a0ed4ffd3df869d30d4ea9ba51948d9
|
Loading…
Reference in New Issue