|
From: <pa...@us...> - 2009-03-09 16:10:26
|
Revision: 2652
http://morphix.svn.sourceforge.net/morphix/?rev=2652&view=rev
Author: paul_c
Date: 2009-03-09 16:10:23 +0000 (Mon, 09 Mar 2009)
Log Message:
-----------
Add recursive an/or force flag to invocations of `rm` - This should reduces the
number of errors logged during (auto)builds.
Modified Paths:
--------------
trunk/mmaker/libmorphix/makebase.c
trunk/mmaker/libmorphix/makemodule.c
Modified: trunk/mmaker/libmorphix/makebase.c
===================================================================
--- trunk/mmaker/libmorphix/makebase.c 2009-03-02 23:52:30 UTC (rev 2651)
+++ trunk/mmaker/libmorphix/makebase.c 2009-03-09 16:10:23 UTC (rev 2652)
@@ -300,7 +300,7 @@
*/
gboolean stripBaseModule(mmodule *module) {
- gchar *cmdline = g_strdup_printf("rm -rf %s/var/cache %s/var/lib/apt %s/var/lib/dpkg",module->dirname,module->dirname,module->dirname);
+ gchar *cmdline = g_strdup_printf("rm -Rf %s/var/cache %s/var/lib/apt %s/var/lib/dpkg",module->dirname,module->dirname,module->dirname);
ExecuteCommand(cmdline);
g_free(cmdline);
@@ -308,11 +308,11 @@
ExecuteCommand(cmdline);
g_free(cmdline);
- cmdline = g_strdup_printf("rm -rf %s/usr/share/doc %s/usr/share/unidata %s/usr/share/locale %s/usr/share/doc",module->dirname,module->dirname,module->dirname,module->dirname);
+ cmdline = g_strdup_printf("rm -Rf %s/usr/share/doc %s/usr/share/unidata %s/usr/share/locale %s/usr/share/doc",module->dirname,module->dirname,module->dirname,module->dirname);
ExecuteCommand(cmdline);
g_free(cmdline);
- cmdline = g_strdup_printf("rm -r %s/usr/share/man %s/usr/share/info %s/usr/share/aptitude",module->dirname,module->dirname,module->dirname);
+ cmdline = g_strdup_printf("rm -Rf %s/usr/share/man %s/usr/share/info %s/usr/share/aptitude",module->dirname,module->dirname,module->dirname);
ExecuteCommand(cmdline);
g_free(cmdline);
/*
Modified: trunk/mmaker/libmorphix/makemodule.c
===================================================================
--- trunk/mmaker/libmorphix/makemodule.c 2009-03-02 23:52:30 UTC (rev 2651)
+++ trunk/mmaker/libmorphix/makemodule.c 2009-03-09 16:10:23 UTC (rev 2652)
@@ -197,7 +197,7 @@
/* Not everyone will agree with this, but it saves quite a bit of space */
- cmdline = g_strdup_printf("%s %s sh -c \"rm -f /var/lib/apt/lists/*\"",P_CHROOT,dirname);
+ cmdline = g_strdup_printf("%s %s sh -c \"rm -fR /var/lib/apt/lists/*\"",P_CHROOT,dirname);
ExecuteCommand(cmdline);
g_free(cmdline);
@@ -487,7 +487,7 @@
}
g_free(cmdline);
- cmdline = g_strdup_printf("rm -r %s/dev/*",dirname);
+ cmdline = g_strdup_printf("rm -fR %s/dev/*",dirname);
if (!ExecuteCommand(cmdline)) {
g_free(cmdline);
fprintf(stderr,"Error: unable to remove /dev/* in chroot\n");
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|