arm-linux-gnueabihf.cmake 1.0 KB

1234567891011121314151617181920212223242526272829
  1. # Copyright 2021 The Draco Authors
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License"); you may not
  4. # use this file except in compliance with the License. You may obtain a copy of
  5. # the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  11. # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  12. # License for the specific language governing permissions and limitations under
  13. # the License.
  14. if(DRACO_CMAKE_TOOLCHAINS_ARM_LINUX_GNUEABIHF_CMAKE_)
  15. return()
  16. endif() # DRACO_CMAKE_TOOLCHAINS_ARM_LINUX_GNUEABIHF_CMAKE_
  17. set(DRACO_CMAKE_TOOLCHAINS_ARM_LINUX_GNUEABIHF_CMAKE_ 1)
  18. set(CMAKE_SYSTEM_NAME "Linux")
  19. if("${CROSS}" STREQUAL "")
  20. set(CROSS arm-linux-gnueabihf-)
  21. endif()
  22. set(CMAKE_CXX_COMPILER ${CROSS}g++)
  23. set(CMAKE_CXX_FLAGS_INIT "-march=armv7-a -marm")
  24. set(CMAKE_SYSTEM_PROCESSOR "armv7")
  25. set(DRACO_NEON_INTRINSICS_FLAG "-mfpu=neon")