]> code.citadel.org Git - citadel.git/blobdiff - webcit/setup.c
Don't try to twiddle /etc/inittab on systems that don't have /etc/inittab.
[citadel.git] / webcit / setup.c
index cfdc7a9c4079785d04e8e51d5d01cb43d3c52f5d..69fad9757cedebaf02c612aa118e5a7f0ce09eb5 100644 (file)
@@ -620,6 +620,15 @@ int main(int argc, char *argv[])
                cleanup(0);
        }
 
+       /* If we're on something BSDish then we don't have inittab */
+       if (access("/etc/inittab", F_OK)) {
+               important_message("Not running SysV style init",
+                               "WebCit Setup can only run on systems that use /etc/inittab.\n"
+                               "Please manually configure your startup scripts to run WebCit\n"
+                               "when the system is booted.\n");
+               cleanup(0);
+       }
+
        /* Get started in a valid setup directory. */
        strcpy(setup_directory, WEBCITDIR);
        if ( (using_web_installer) && (getenv("WEBCIT") != NULL) ) {