-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
211 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,24 @@ | ||
INCLUDE (CheckIncludeFiles) | ||
CHECK_INCLUDE_FILES ("sys/statvfs.h;mntent.h" INFO_HEADERS LANGUAGE CXX) | ||
|
||
IF (INFO_HEADERS) | ||
CHECK_SYMBOL_EXISTS (getmntent "mntent.h" HAVE_GETMNTENT) | ||
CHECK_SYMBOL_EXISTS (getmntent "sys/mnttab.h" HAVE_GETMNTENT_IN_SYS_MNTAB) | ||
CHECK_SYMBOL_EXISTS (setmntent "mntent.h" HAVE_SETMNTENT) | ||
CHECK_SYMBOL_EXISTS (getmntinfo "sys/types.h;sys/mount.h" HAVE_GETMNTINFO) | ||
CHECK_SYMBOL_EXISTS (getmntinfo64 "sys/types.h;sys/mount.h" HAVE_GETMNTINFO64) | ||
|
||
IF (HAVE_GETMNTINFO) | ||
CHECK_CXX_SOURCE_COMPILES(" | ||
#include <sys/types.h> | ||
#include <sys/statvfs.h> | ||
int main() | ||
{ | ||
struct statvfs *s; | ||
return getmntinfo(&s, ST_WAIT); | ||
} | ||
" HAVE_GETMNTINFO_TAKES_statvfs) | ||
ENDIF() | ||
IF (HAVE_GETMNTENT OR HAVE_GETMNTENT_IN_SYS_MNTAB OR | ||
HAVE_GETMNTINFO OR HAVE_GETMNTINFO64) | ||
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/sql) | ||
MYSQL_ADD_PLUGIN(DISKS information_schema_disks.cc MODULE_ONLY RECOMPILE_FOR_EMBEDDED) | ||
ENDIF() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
--replace_regex /varchar\([0-9]+\)/varchar(pathlen)/ | ||
show create table information_schema.disks; | ||
select sum(Total) > sum(Available), sum(Total)>sum(Used) from information_schema.disks; |