Mercurial > minori
annotate dep/animia/src/fd.cc @ 201:8f6f8dd2eb23
dep/animia: finish kvm backend
dep/animia: cmake: don't use kvm on unsupported systems, use private and public includes properly
cmake: why are we defining target include directories twice?
author | paper@DavesDouble.local |
---|---|
date | Sun, 19 Nov 2023 19:13:28 -0500 |
parents | 54c5d80a737e |
children | 71832ffe425a |
rev | line source |
---|---|
146
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
1 #include "animia/fd.h" |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
2 |
152
8700806c2cc2
dep/animia: awesome new breaking changes!
Paper <mrpapersonic@gmail.com>
parents:
150
diff
changeset
|
3 #ifdef WIN32 |
146
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
4 # include "animia/fd/win32.h" |
166 | 5 #elif defined(LINUX) || defined(FREEBSD) |
6 # include "animia/fd/proc.h" | |
153
bd439dd6ffc5
*: make win stuff actually work, rename bsd.cc to xnu.cc
Paper <mrpapersonic@gmail.com>
parents:
152
diff
changeset
|
7 #elif defined(MACOSX) |
bd439dd6ffc5
*: make win stuff actually work, rename bsd.cc to xnu.cc
Paper <mrpapersonic@gmail.com>
parents:
152
diff
changeset
|
8 # include "animia/fd/xnu.h" |
166 | 9 #elif defined(LIBUTIL) |
10 # include "animia/fd/libutil.h" | |
201 | 11 #elif defined(LIBKVM) |
12 # include "animia/fd/kvm.h" | |
146
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
13 #endif |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
14 |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
15 namespace animia::internal { |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
16 |
152
8700806c2cc2
dep/animia: awesome new breaking changes!
Paper <mrpapersonic@gmail.com>
parents:
150
diff
changeset
|
17 #ifdef WIN32 |
146
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
18 win32::Win32FdTools os_fd; |
166 | 19 #elif defined(LINUX) || defined(FREEBSD) |
20 proc::ProcFdTools os_fd; | |
153
bd439dd6ffc5
*: make win stuff actually work, rename bsd.cc to xnu.cc
Paper <mrpapersonic@gmail.com>
parents:
152
diff
changeset
|
21 #elif defined(MACOSX) |
bd439dd6ffc5
*: make win stuff actually work, rename bsd.cc to xnu.cc
Paper <mrpapersonic@gmail.com>
parents:
152
diff
changeset
|
22 xnu::XnuFdTools os_fd; |
166 | 23 #elif defined(LIBUTIL) |
24 libutil::LibutilFdTools os_fd; | |
201 | 25 #elif defined(LIBKVM) |
26 kvm::KvmFdTools os_fd; | |
146
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
27 #else |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
28 BaseFdTools os_fd; |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
29 #endif |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
30 |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
31 BaseFdTools& fd = os_fd; |
d8a61e7e2a36
dep/animia: move fd stuff to a new fd.cc, don't force the user
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
32 |
156
cdf79282d647
dep/animia: add VERY early x11 window stuff
Paper <mrpapersonic@gmail.com>
parents:
153
diff
changeset
|
33 } // namespace animia::internal |