SF.net SVN: morphix: [2404] trunk/mmaker/libmorphix

[email protected] Tue, 29 Aug 2006 17:57:20 -0700
Newsgroups gmane.linux.morphix.cvs
Message-ID <[email protected]>
Revision: 2404
Author:   alextreme
Date:     2006-08-29 17:57:13 -0700 (Tue, 29 Aug 2006)
ViewCVS:  http://svn.sourceforge.net/morphix/?rev=2404&view=rev

Log Message:
-----------
  * -s fix?

Modified Paths:
--------------
    trunk/mmaker/libmorphix/makebase.c
    trunk/mmaker/libmorphix/makebase.h
    trunk/mmaker/libmorphix/makemain.c
    trunk/mmaker/libmorphix/makemain.h
    trunk/mmaker/libmorphix/makemodule.c
    trunk/mmaker/libmorphix/makemodule.h
Modified: trunk/mmaker/libmorphix/makebase.c
===================================================================
--- trunk/mmaker/libmorphix/makebase.c	2006-08-27 22:27:10 UTC (rev 2403)
+++ trunk/mmaker/libmorphix/makebase.c	2006-08-30 00:57:13 UTC (rev 2404)
@@ -181,8 +181,8 @@
    return TRUE/FALSE
 */
 
-gboolean addPackagesBaseModule(mmodule *module, GList *extra_package_list) {
-	return addPackages(module, TRUE, extra_package_list);
+gboolean addPackagesBaseModule(mmodule *module, GList *extra_package_list, gchar *sources_location) {
+	return addPackages(module, TRUE, extra_package_list, sources_location);
 }
 
 /**

Modified: trunk/mmaker/libmorphix/makebase.h
===================================================================
--- trunk/mmaker/libmorphix/makebase.h	2006-08-27 22:27:10 UTC (rev 2403)
+++ trunk/mmaker/libmorphix/makebase.h	2006-08-30 00:57:13 UTC (rev 2404)
@@ -5,7 +5,7 @@
 
 gboolean initBaseModule(mmodule *module,gchar *xmlfilename,gchar *debtarball, gchar* debbzip2,gchar *debootdir);
 
-gboolean addPackagesBaseModule(mmodule *module, GList *extra_package_list);
+gboolean addPackagesBaseModule(mmodule *module, GList *extra_package_list, gchar *sources_location);
 
 gboolean stripBaseModule(mmodule *module);
 gboolean moveKernel(mmodule *module);

Modified: trunk/mmaker/libmorphix/makemain.c
===================================================================
--- trunk/mmaker/libmorphix/makemain.c	2006-08-27 22:27:10 UTC (rev 2403)
+++ trunk/mmaker/libmorphix/makemain.c	2006-08-30 00:57:13 UTC (rev 2404)
@@ -151,7 +151,7 @@
    return TRUE/FALSE
 */
 
-gboolean addPackagesMainModule(mmodule *module, GList *extra_package_list) {
+gboolean addPackagesMainModule(mmodule *module, GList *extra_package_list, gchar *sources_location) {
 	gchar *proxyfile;
 	gchar *cmdline;
 	FILE *FD_proxy;
@@ -171,7 +171,7 @@
 		fclose(FD_proxy);
 		g_free(proxyfile);
 	}
-	ret = addPackages(module,FALSE, extra_package_list);
+	ret = addPackages(module,FALSE, extra_package_list, sources_location);
 	if (module->proxy != NULL) {
 		cmdline = g_strdup_printf("rm -f /etc/apt/apt.conf.d/50proxy");
 		if (!ExecuteCommand(cmdline)) {

Modified: trunk/mmaker/libmorphix/makemain.h
===================================================================
--- trunk/mmaker/libmorphix/makemain.h	2006-08-27 22:27:10 UTC (rev 2403)
+++ trunk/mmaker/libmorphix/makemain.h	2006-08-30 00:57:13 UTC (rev 2404)
@@ -5,6 +5,6 @@
 #include "parsemod.h"
 
 gboolean initMainModule(mmodule *module,gchar *xmlfilename,gchar *debtarball,gchar* debbzip2, gchar *debootdir);
-gboolean addPackagesMainModule(mmodule *module, GList *extra_package_list);
+gboolean addPackagesMainModule(mmodule *module, GList *extra_package_list, gchar *sources_location);
 
 #endif

Modified: trunk/mmaker/libmorphix/makemodule.c
===================================================================
--- trunk/mmaker/libmorphix/makemodule.c	2006-08-27 22:27:10 UTC (rev 2403)
+++ trunk/mmaker/libmorphix/makemodule.c	2006-08-30 00:57:13 UTC (rev 2404)
@@ -925,7 +925,7 @@
    return TRUE/FALSE
 */
 
-gboolean addPackages(mmodule *module, gboolean depmod, GList *extra_package_list) {
+gboolean addPackages(mmodule *module, gboolean depmod, GList *extra_package_list, gchar *sources_location) {
 	gchar *cmdline = NULL;
 	if (module == NULL) {
 		fprintf(stderr,"Error: mmodule* == NULL\n");
@@ -983,6 +983,10 @@
 
 	savePackageList(module,module->dirname);
 
+	if (!getAptPackageSources(module, sources_location)) {
+		return FALSE;
+	}
+
 	deleteCruft(module->dirname);
 
         if (!cleanApt(module,module->dirname)) {
@@ -1232,7 +1236,8 @@
 	    simply isn't enough...
 	*/
 
-	cmdline = g_strdup_printf("%s %s sh -c \"COLUMNS=160 dpkg -l\"",P_CHROOT,module->dirname);
+	cmdline = g_strdup_printf("%s %s sh -c \"COLUMNS=160 dpkg -l | gzip > /morphix/packages.gz\"",P_CHROOT,module->dirname);
+
 	stdinput = ExecuteCommandReturnStdin(cmdline);
 	g_free(cmdline);
 	buf_array = g_strsplit(stdinput,"\n",0);
@@ -1346,15 +1351,12 @@
 		if (!disableDaemons(module)) {
 			return FALSE;
 		}
-		if (!addPackagesMainModule(module, extra_package_list)) {
+		if (!addPackagesMainModule(module, extra_package_list, sources_location)) {
 			return FALSE;
 		}
 		if (!installLocalPackages(module)) {
 			return FALSE;
 		}
-		if (!getAptPackageSources(module, sources_location)) {
-			return FALSE;
-		}
 		if (!executeRetrieveFiles(module)) {
 			return FALSE;
 		}
@@ -1378,15 +1380,12 @@
 		if (!disableDaemons(module)) {
 			return FALSE;
 		}
-		if (!addPackagesBaseModule(module, extra_package_list)) {
+		if (!addPackagesBaseModule(module, extra_package_list, sources_location)) {
 			return FALSE;
 		}
 		if (!installLocalPackages(module)) {
 			return FALSE;
 		}
-		if (!getAptPackageSources(module, sources_location)) {
-			return FALSE;
-		}
 		if (!moveMorphixEtcFiles(module)) {
 			return FALSE;
 		}

Modified: trunk/mmaker/libmorphix/makemodule.h
===================================================================
--- trunk/mmaker/libmorphix/makemodule.h	2006-08-27 22:27:10 UTC (rev 2403)
+++ trunk/mmaker/libmorphix/makemodule.h	2006-08-30 00:57:13 UTC (rev 2404)
@@ -30,7 +30,7 @@
 gboolean executePatches(mmodule *module, gchar *dirname);
 gboolean addRepositories(mmodule *module,gchar *dirname);
 gboolean setupDebootstrap(mmodule *module);
-gboolean addPackages(mmodule *module, gboolean depmod, GList *extra_package_list);
+gboolean addPackages(mmodule *module, gboolean depmod, GList *extra_package_list, gchar *sources_location);
 gboolean getAptPackageSources(mmodule *module, gchar *sources_location);
 gboolean makeModuleToFile(mmodule *module,gchar *xmlfilename,gchar *outputfilename,gboolean leave_dir, gchar *debtarball, gchar *debbzip2,gchar *debootdir, GList *extra_package_list, gchar *sources_location);
 gboolean bindDevProc(mmodule *module,gchar *dirname);


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642