Changeset 1688

Show
Ignore:
Timestamp:
26/05/2007 16:30:05 (20 months ago)
Author:
chris
Message:

Don't define default locations for config files at compile time on Windows,
provide macros to determine them at runtime instead.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • box/chris/general/lib/common/BoxPortsAndFiles.h

    r217 r1688  
    1515 
    1616// Backup store daemon 
    17 #define BOX_PORT_BBSTORED                                       (BOX_PORT_BASE+1) 
    18 #define BOX_FILE_BBSTORED_DEFAULT_CONFIG        "/etc/box/bbstored.conf" 
     17#define BOX_PORT_BBSTORED                       (BOX_PORT_BASE+1) 
     18 
    1919// directory within the RAIDFILE root for the backup store daemon 
    20 #define BOX_RAIDFILE_ROOT_BBSTORED                      "backup" 
     20#define BOX_RAIDFILE_ROOT_BBSTORED              "backup" 
    2121 
    22 // Backup client daemon 
     22// configuration file paths 
    2323#ifdef WIN32 
    24 #define BOX_FILE_BBACKUPD_DEFAULT_CONFIG        "C:\\Program Files\\Box Backup\\bbackupd.conf" 
     24        // no default config file path, use these macros to call 
     25        // GetDefaultConfigFilePath() instead. 
     26 
     27        #define BOX_GET_DEFAULT_BBACKUPD_CONFIG_FILE \ 
     28                GetDefaultConfigFilePath("bbackupd.conf").c_str() 
     29        #define BOX_GET_DEFAULT_RAIDFILE_CONFIG_FILE \ 
     30                GetDefaultConfigFilePath("raidfile.conf").c_str() 
     31        #define BOX_GET_DEFAULT_BBSTORED_CONFIG_FILE \ 
     32                GetDefaultConfigFilePath("bbstored.conf").c_str() 
    2533#else 
    2634#define BOX_FILE_BBACKUPD_DEFAULT_CONFIG        "/etc/box/bbackupd.conf" 
     35#define BOX_FILE_RAIDFILE_DEFAULT_CONFIG        "/etc/box/raidfile.conf" 
     36#define BOX_FILE_BBSTORED_DEFAULT_CONFIG        "/etc/box/bbstored.conf" 
    2737#endif 
    28  
    29 // RaidFile conf location default 
    30 #define BOX_FILE_RAIDFILE_DEFAULT_CONFIG        "/etc/box/raidfile.conf" 
    3138 
    3239// Default name of the named pipe