Fix miniz include.
PiperOrigin-RevId: 914519929 Change-Id: I0dc00ef3f4518571165e4be0e85016511e0cdd60
This commit is contained in:
committed by
Copybara-Service
parent
a4e49f2dff
commit
99e626096f
@@ -247,13 +247,25 @@ if(WIN32)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(DEFINED BUILD_TESTS)
|
||||||
|
set(_OLD_BUILD_TESTS "${BUILD_TESTS}")
|
||||||
|
set(_BUILD_TESTS_WAS_DEFINED TRUE)
|
||||||
|
else()
|
||||||
|
set(_BUILD_TESTS_WAS_DEFINED FALSE)
|
||||||
|
endif()
|
||||||
set(BUILD_TESTS OFF)
|
set(BUILD_TESTS OFF)
|
||||||
fetchpackage(
|
fetchpackage(
|
||||||
PACKAGE_NAME miniz
|
PACKAGE_NAME miniz
|
||||||
GIT_REPO https://github.com/richgel999/miniz.git
|
GIT_REPO https://github.com/richgel999/miniz.git
|
||||||
GIT_TAG ${MUJOCO_DEP_VERSION_miniz}
|
GIT_TAG ${MUJOCO_DEP_VERSION_miniz}
|
||||||
TARGETS miniz
|
TARGETS miniz
|
||||||
)
|
)
|
||||||
|
if(_BUILD_TESTS_WAS_DEFINED)
|
||||||
|
set(BUILD_TESTS "${_OLD_BUILD_TESTS}")
|
||||||
|
else()
|
||||||
|
unset(BUILD_TESTS)
|
||||||
|
endif()
|
||||||
|
unset(_BUILD_TESTS_WAS_DEFINED)
|
||||||
|
|
||||||
|
|
||||||
if(MUJOCO_BUILD_TESTS OR MUJOCO_BUILD_STUDIO OR MUJOCO_USE_FILAMENT)
|
if(MUJOCO_BUILD_TESTS OR MUJOCO_BUILD_STUDIO OR MUJOCO_USE_FILAMENT)
|
||||||
|
|||||||
@@ -24,7 +24,20 @@
|
|||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include <miniz_zip.h>
|
#if defined(__clang__)
|
||||||
|
#pragma clang diagnostic push
|
||||||
|
#pragma clang diagnostic ignored "-Wunused-function"
|
||||||
|
#elif defined(__GNUC__)
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Wunused-function"
|
||||||
|
#endif
|
||||||
|
#include <miniz.h>
|
||||||
|
#if defined(__clang__)
|
||||||
|
#pragma clang diagnostic pop
|
||||||
|
#elif defined(__GNUC__)
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <mujoco/mjspec.h>
|
#include <mujoco/mjspec.h>
|
||||||
#include <mujoco/mujoco.h>
|
#include <mujoco/mujoco.h>
|
||||||
#include "user/user_resource.h"
|
#include "user/user_resource.h"
|
||||||
|
|||||||
Reference in New Issue
Block a user