[Frugalware-darcs] setup-current: loadsource: new function: is_dvd()

VMiklos vmiklos at frugalware.org
Thu Mar 16 18:01:21 CET 2006


[loadsource: new function: is_dvd()
VMiklos <vmiklos at frugalware.org>**20051118213849] {
hunk ./src/plugins/loadsource.c 91
+int is_dvd(char *path)
+{
+	struct stat statbuf;
+	if(!((!stat(g_strdup_printf("%s/frugalware-%s", path, ARCH), &statbuf)
+		&& S_ISDIR(statbuf.st_mode)) &&
+		(!stat(g_strdup_printf("%s/extra/frugalware-%s", path, ARCH),
+		&statbuf) && S_ISDIR(statbuf.st_mode))))
+		return(1);
+	else
+		return(0);
+}
+
hunk ./src/plugins/loadsource.c 136
+			if(is_dvd(SOURCEDIR))
+				data_put(config, "dvd", "");
}


More information about the Frugalware-darcs mailing list