[ox/std] Add gcc library as dependency when building with GCC
This commit is contained in:
parent
1bf3809b47
commit
2b60c04f1a
6
deps/ox/src/ox/std/CMakeLists.txt
vendored
6
deps/ox/src/ox/std/CMakeLists.txt
vendored
@ -1,6 +1,5 @@
|
||||
add_library(
|
||||
OxStd
|
||||
arith.cpp
|
||||
assert.cpp
|
||||
buildinfo.cpp
|
||||
byteswap.cpp
|
||||
@ -19,6 +18,11 @@ set_property(
|
||||
POSITION_INDEPENDENT_CODE ON
|
||||
)
|
||||
|
||||
target_link_libraries(
|
||||
OxStd PUBLIC
|
||||
$<$<CXX_COMPILER_ID:GNU>:gcc>
|
||||
)
|
||||
|
||||
install(
|
||||
FILES
|
||||
assert.hpp
|
||||
|
44
deps/ox/src/ox/std/arith.cpp
vendored
44
deps/ox/src/ox/std/arith.cpp
vendored
@ -1,44 +0,0 @@
|
||||
/*
|
||||
* Copyright 2015 - 2018 gtalent2@gmail.com
|
||||
*
|
||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
#include "hardware.hpp"
|
||||
|
||||
// these provide software implementations of arithmetic operators expected by
|
||||
// the compiler on older processors
|
||||
|
||||
#if !OX_HW_DIV
|
||||
|
||||
extern "C" {
|
||||
|
||||
unsigned __aeabi_uldivmod(unsigned, unsigned) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
unsigned __aeabi_uidiv(unsigned, unsigned) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
unsigned __aeabi_uimod(unsigned, unsigned) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
unsigned __aeabi_uidivmod(unsigned, unsigned) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
signed __aeabi_idiv(signed, signed) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
signed __aeabi_imod(signed, signed) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#endif
|
Loading…
x
Reference in New Issue
Block a user