Skip to content

Commit

Permalink
Switched to header only UUID implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
timschwartz committed Mar 20, 2022
1 parent 1e0e942 commit 18901c4
Show file tree
Hide file tree
Showing 7 changed files with 991 additions and 36 deletions.
27 changes: 26 additions & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


nlohmann/json
nlohmann/json - https://github.com/nlohmann/json
-------------
MIT License

Expand All @@ -47,3 +47,28 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


mariusbancila/stduuid - https://github.com/mariusbancila/stduuid
---------------------
MIT License

Copyright (c) 2017

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
6 changes: 0 additions & 6 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,6 @@ AC_CONFIG_MACRO_DIR([m4])
AC_PROG_CXX
AM_INIT_AUTOMAKE([subdir-objects])

AC_CHECK_HEADER(
[windows.h],
[UUID_LIBS="-lrpcrt4 $LIBS"; AC_SUBST([UUID_REQUIRE], "")],
[PKG_CHECK_MODULES([UUID], uuid, AC_SUBST([UUID_REQUIRE], "uuid"))]
)

AC_CONFIG_FILES([Doxyfile])
AC_CONFIG_FILES([ecs-cpp.pc])
AC_CONFIG_FILES([Makefile src/Makefile])
Expand Down
2 changes: 1 addition & 1 deletion include/libecs-cpp/Entity.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ namespace ecs
Entity(ecs::Container *Container);
Entity(ecs::Container *Container, std::string Handle);
nlohmann::json Export();
ecs::Container *Container;
const std::string Handle;
ecs::Container *Container = nullptr;
std::shared_ptr<ecs::Component> Component(ecs::Component *component);
void Destroy();
void ComponentDestroy(std::string Type);
Expand Down
8 changes: 2 additions & 6 deletions include/libecs-cpp/Uuid.hpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
#pragma once
#include <string>

#ifdef _WIN32
#include <rpc.h>
#else
#include <uuid/uuid.h>
#endif
#include <libecs-cpp/uuid.h>

namespace ecs
{
Expand All @@ -16,6 +12,6 @@ namespace ecs
Uuid(std::string);
std::string Get();
private:
std::string uuid;
uuids::uuid id;
};
}
Loading

0 comments on commit 18901c4

Please sign in to comment.