Skip to content

Commit

Permalink
Install zpool compatibility.d files
Browse files Browse the repository at this point in the history
Use C:/Program Files/OpenZFS on Windows/compatibility.d/

Signed-off-by: Jorgen Lundman <[email protected]>
  • Loading branch information
lundman committed Apr 15, 2024
1 parent 7b74276 commit 4b326b9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 3 additions & 2 deletions contrib/windows/Inno.Setup/ZFSInstall-debug.iss
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#expr FileClose(VerFile)
#undef VerFile
; Parse out 2.0.0-7-g689dbcfbf-dirty and delete the double-quote
#define MyAppVersion StringChange(Copy(VerStr, 30), '"','')
#define MyAppVersion StringChange(Copy(VerStr, 33), '"','')

#pragma message MyAppVersion + " is version"

Expand Down Expand Up @@ -108,7 +108,8 @@ Source: "{#Root}\out\build\x64-Debug\cmd\os\windows\kstat\*.pdb"; DestDir: "{app
Source: "{#SourcePath}\HowToDebug.txt"; DestDir: "{app}"; Flags: ignoreversion
Source: "{#Root}\contrib\windows\parsedump\*.*"; DestDir: "{app}"; Flags: ignoreversion
Source: "{#Root}\scripts\zfs_prepare_disk"; DestDir: "{app}"; Flags: ignoreversion

Source: "{#Root}\cmd\zpool\compatibility.d\*"; DestDir: "{app}\compatibility.d"; Flags: ignoreversion
Source: "{#Root}\cmd\zpool\zpool.d\*"; DestDir: "{app}\zpool.d"; Flags: ignoreversion

; NOTE: Don't use "Flags: ignoreversion" on any shared system files

Expand Down
6 changes: 6 additions & 0 deletions include/sys/fs/zfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -983,8 +983,14 @@ typedef struct zpool_load_policy {
/*
* Settings for zpool compatibility features files
*/
#ifdef _WIN32
/* Lets stay away from C:/windows */
#define ZPOOL_SYSCONF_COMPAT_D ZFSEXECDIR "\\compatibility.d"
#define ZPOOL_DATA_COMPAT_D ZFSEXECDIR "\\compatibility.d"
#else
#define ZPOOL_SYSCONF_COMPAT_D SYSCONFDIR "/zfs/compatibility.d"
#define ZPOOL_DATA_COMPAT_D PKGDATADIR "/compatibility.d"
#endif
#define ZPOOL_COMPAT_MAXSIZE 16384

/*
Expand Down

0 comments on commit 4b326b9

Please sign in to comment.