thin-provisioning-tools: fix musl
This commit is contained in:
parent
3b7eaee7b6
commit
a0ece13ad7
1 changed files with 42 additions and 0 deletions
42
srcpkgs/thin-provisioning-tools/patches/musl.patch
Normal file
42
srcpkgs/thin-provisioning-tools/patches/musl.patch
Normal file
|
@ -0,0 +1,42 @@
|
|||
--- block-cache/io_engine.h.orig 2017-03-27 15:00:54.000000000 +0200
|
||||
+++ block-cache/io_engine.h 2017-06-13 23:49:37.403053236 +0200
|
||||
@@ -10,13 +10,17 @@
|
||||
#include <libaio.h>
|
||||
#include <vector>
|
||||
|
||||
+#include <limits.h>
|
||||
+#ifndef PAGE_SIZE
|
||||
+#define PAGE_SIZE sysconf(_SC_PAGE_SIZE)
|
||||
+#endif
|
||||
+
|
||||
//----------------------------------------------------------------
|
||||
|
||||
namespace bcache {
|
||||
using sector_t = uint64_t;
|
||||
|
||||
unsigned const SECTOR_SHIFT = 9;
|
||||
- unsigned const PAGE_SIZE = 4096;
|
||||
|
||||
// Virtual base class to aid unit testing
|
||||
class io_engine {
|
||||
--- unit-tests/io_engine_t.cc.orig 2017-03-27 15:00:54.000000000 +0200
|
||||
+++ unit-tests/io_engine_t.cc 2017-06-13 23:58:17.674546348 +0200
|
||||
@@ -23,6 +23,10 @@
|
||||
|
||||
|
||||
#include <fcntl.h>
|
||||
+#include <limits.h>
|
||||
+#ifndef PAGE_SIZE
|
||||
+#define PAGE_SIZE sysconf(_SC_PAGE_SIZE)
|
||||
+#endif
|
||||
|
||||
using namespace boost;
|
||||
using namespace std;
|
||||
@@ -33,7 +37,6 @@
|
||||
|
||||
namespace {
|
||||
unsigned const MAX_IO = 64;
|
||||
- unsigned const PAGE_SIZE = 4096;
|
||||
|
||||
class IOEngineTests : public Test {
|
||||
public:
|
Loading…
Reference in a new issue