Commit graph

78 commits

Author SHA1 Message Date
Alexandre Bouvier
9d369436d8 cmake: Fix unicorn and llvm 2022-03-22 20:27:01 +00:00
Andrea Pappacoda
e4b669fd5b build: remove extra include path for system vixl
As far as I know the only pkg-config file provided by Vixl is the one generated by Meson when applying my yet to be merged patch.

That extra include path was needed because I mistakenly thought that adding `vixl` as an include subdirectory was not necessary, but I fixed it in my latest revision - more details here: https://github.com/Linaro/vixl/pull/7#discussion_r778167004

The fix already landed in Debian and Ubuntu, that as far as I know are the only Linux distros that ship my patch, so manually adding that include directory shouldn't be necessary anymore
2022-03-13 20:24:26 +00:00
Merry
5092972843 CMakeLists: Use system vixl when able 2022-02-26 13:35:36 +00:00
Andrea Pappacoda
4dcebc1822 build(cmake): add install target
This makes dynarmic installable, and also adds a CMake package config
file, that allows projects to use `find_package(dynarmic)` to import the
library.

I know #636 adds the same thing, but while experimenting with the
different install options in
https://github.com/merryhime/dynarmic/pull/636#discussion_r725656034
I ended up with a working patch, so I'm proposing this as well. This
implements solution 2.
2021-10-30 19:03:23 +01:00
Andrea Pappacoda
b87a889d98 build(cmake): add version and soversion to the library
This adds versioning information to the built library.

When building the shared library on Linux systems, a new object will
be created: libdynarmic.so.5

This is really useful when talking about ABI compatibility.

The variables dynarmic_VERSION and dynarmic_VERSION_MAJOR
are implicitly created when calling project(dynarmic VERSION x.y.z)
2021-10-11 06:53:05 +01:00
ameerj
55bede81f8 CMake: Fix fmt target check 2021-10-11 06:52:52 +01:00
merry
1697902948
Merge pull request #641 from abouvier/unbundle
CMakeLists: Add options to unbundle most external libraries
2021-08-25 07:56:12 +01:00
Alexandre Bouvier
352898e88b cmake: Add options to unbundle Zydis 2021-08-24 12:28:44 +02:00
Merry
2e4f99ae3d CMakeLists: Expose DYNARMIC_IGNORE_ASSERTS option 2021-08-15 16:09:37 +01:00
Merry
3b4459d112 CMakeLists: Enable C++20 support 2021-08-15 15:17:01 +01:00
Alexandre Bouvier
04b1c78166 cmake: Add checks for projects using dynarmic as subproject 2021-08-10 16:16:02 +02:00
Alexandre Bouvier
33b89cca08 cmake: Add options to unbundle some externals 2021-08-10 16:05:38 +02:00
Merry
714216fd0e Consolidate all source files into src/ directory 2021-05-19 17:41:59 +01:00
MerryMage
7bc9e36ed7 emit_x64_floating_point: Optimize 32-bit EmitFPRSqrtEstimate 2021-04-26 00:26:28 +01:00
MerryMage
52a9af3dca CMakeLists: Rework architecture detection
* Also only enable xybak/vixl on appropriate architectures
2021-03-02 20:41:38 +00:00
MerryMage
b841ce1df5 CMakeLists: Increase maximum bracket depth for Clang
See also: https://reviews.llvm.org/D86936
Bracket depth limits size of fold expression which in turn limits size of std::array initialization via CTAD
2021-02-16 20:12:10 +00:00
MerryMage
e85a08ec34 CMakeLists: MSVC: Weaken warning level for externals 2020-05-26 20:52:06 +01:00
MerryMage
d0075f4ea6 print_info: Use LLVM to disassemble A32 2020-05-17 22:30:46 +01:00
MerryMage
69061d87fa exception_handler_windows: Ignore irrelevant exceptions 2020-04-23 20:58:24 +01:00
MerryMage
e41fef4a2a CMakeLists: option only works for boolean settings 2020-04-22 21:06:18 +01:00
MerryMage
7c917f1c12 CMakeLists: Add DYNARMIC_FRONTENDS option
Allows library user to select which frontends to enable
2020-04-22 21:06:18 +01:00
MerryMage
2d348d2d68 backend/x64: Add macOS exception handler with fastmem support 2020-04-22 21:06:18 +01:00
MerryMage
6edc95e9eb CMakeLists: Put -Wfatal-errors behind a CMake flag 2020-04-22 21:04:23 +01:00
Lioncash
9d33ea3136 CMakeLists: Specify the /volatile flag with standard-conforming semantics
Makes Windows builds more standard-compliant. Given we currently make no
use of volatile, and the libraries we currently use don't use it any
meaningful way, this is safe to specify without worrying.
2020-04-22 21:02:47 +01:00
Lioncash
0d3375fc22 CMakeLists: Add /Zc:externConstexpr compilation flag
Improves standard conformance on Windows builds.
2020-04-22 21:02:47 +01:00
Lioncash
3b2b47b522 CMakeLists: Remove setting of CMAKE_WARN_DEPRECATED
CMake documentation states:
    "If this variable is not set, CMake behaves as if it were set to TRUE."

So this isn't needed, as it's the default behavior.
2020-04-22 21:02:47 +01:00
Lioncash
df996a8375 CMakeLists: Turn generic target path into an error
There's currently no way this path can occur and result in any
functioning executable. The recompiler backends are platform-specific.
If those platforms aren't available, then it's quite literally
impossible to use this library for anything meaningful. Instead of
defining a generic architecture and continuing on, notify the developer
that their platform is not currently supported.
2020-04-22 21:02:47 +01:00
Lioncash
750ceb9701 CMakeLists: Remove detection of 32-bit platforms
We currently have no plans to add 32-bit host architecture support, so
we don't even need to check for these platforms.
2020-04-22 21:02:47 +01:00
MerryMage
d5b9c4a4bb block_of_code: Hide NX support behind compiler flag
Systems that require W^X can use the DYNARMIC_ENABLE_NO_EXECUTE_SUPPORT cmake option.
2020-04-22 20:53:46 +01:00
Lioncash
ed11c7d904 CMakeLists: Add detection for Aarch64 compiler environments
Just closes a small hole in architecture detection for the ARM family.
2020-04-22 20:46:17 +01:00
Lioncash
cd0b71159a CMake: Make FindUnicorn introduce a unicorn target
Makes the find module do all the work of properly setting up the target instead of needing to do it in the main CMakeLists file.
2020-04-22 20:46:16 +01:00
MerryMage
e97581d063 fuzz_with_unicorn: Print AArch64 disassembly 2020-04-22 20:46:14 +01:00
MerryMage
a90e4955ab CMakeLists: Ignore warnings within xbyak 2020-04-22 20:46:14 +01:00
MerryMage
30936f5e94 travis: Test with disabled CPU feature detection
Ensure that fallbacks are working correctly.
2020-04-22 20:44:37 +01:00
MerryMage
a59e9ad9c6 travis: Run A64 tests 2020-04-22 20:42:45 +01:00
MerryMage
d5725de26a tests/A64: Fuzz against unicorn 2020-04-22 20:42:45 +01:00
MerryMage
cde2d48eb9 CMakeLists: CMAKE_CXX_STANDARD as no effect on MSVC until CMake 3.10
We add the /std:c++latest flag to DYNARMIC_CXX_FLAGS to fix this.
2020-04-22 20:39:27 +01:00
MerryMage
89e9ce8aff Bump requirements to C++17 2020-04-22 20:27:15 +01:00
MerryMage
0af1e7723d CMakeLists: Fixup boost
* boost is part of the public interface.
* Consider boost a system library so warnings from boost do not cause a build failure.
* If the parent project defines boost, use that.
2020-04-22 20:26:40 +01:00
MerryMage
d00ce34432 CMakeLists: Default to a Release build 2020-04-22 20:26:12 +01:00
MerryMage
5beb61913b CMakeLists: Remove unnecessary -msse3 option 2017-07-08 16:33:20 +01:00
Yuri Kunde Schlesner
8f15e3f70c CMakeLists: Enable stricter C++ conformance mode in MSVC 2017-06-12 07:57:46 +01:00
Yuri Kunde Schlesner
38eb7e0314 emit_x64: Use alternative Xbyak names for and, or, xor
Also enabled XBYAK_NO_OP_NAMES, allowing us to stop using
-fno-operator-names.
2017-06-12 07:57:46 +01:00
Lioncash
9906be746f CMakeLists: Make boost an interface library target
Gets rid of the use of a non-target include and makes libraries
explicitly link against the identifier name in order to get includes.
2017-03-04 11:52:32 +00:00
Lioncash
f9e7e85308 externals: Make catch an interface target
Eliminates top-level inclusion of the headers with include_directories()
and instead utilizes it on a by-target basis using target_include_directories().
2017-02-26 13:43:47 +00:00
Lioncash
c92a6a5eb7 CMakeLists: Change set into a list append
Same thing, less repetition.

Also puts quotes around the added path to correctly handle any spaces in paths.
2017-02-23 15:13:19 +00:00
MerryMage
e8b6e76fbf CMakeLists: Drop -Wno-unused-parameter 2017-02-22 23:52:18 +00:00
Lioncash
a2d4db575f CMakeLists: Drop FATAL_ERROR from cmake_minimum_required
This is ignored by CMake 2.6 and higher.
2017-02-22 20:24:03 +00:00
MerryMage
a77710e5cf CMake: Add option DYNARMIC_WARNINGS_AS_ERRORS 2017-02-04 20:31:10 +00:00
MerryMage
cc58666c06 CMakeLists: Use target_compile_options intead of add_compile_options 2016-12-19 00:48:25 +00:00