<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> <HTML> <HEAD> <TITLE> [Mageia-dev] [soft-commits] [5686] For non-local media, iurt is suppressing the urpmi. cfg file while creating </TITLE> <LINK REL="Index" HREF="index.html" > <LINK REL="made" HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20%5Bsoft-commits%5D%20%5B5686%5D%20For%20non-local%20media%2C%0A%09iurt%20is%20suppressing%20the%20urpmi.%20cfg%20file%20while%20creating&In-Reply-To=%3C877gs7qxy5.fsf%40lebrac.rtp-net.org%3E"> <META NAME="robots" CONTENT="index,nofollow"> <META http-equiv="Content-Type" content="text/html; charset=us-ascii"> <LINK REL="Previous" HREF="018500.html"> <LINK REL="Next" HREF="018490.html"> </HEAD> <BODY BGCOLOR="#ffffff"> <H1>[Mageia-dev] [soft-commits] [5686] For non-local media, iurt is suppressing the urpmi. cfg file while creating</H1> <B>Arnaud Patard (Rtp)</B> <A HREF="mailto:mageia-dev%40mageia.org?Subject=Re%3A%20%5BMageia-dev%5D%20%5Bsoft-commits%5D%20%5B5686%5D%20For%20non-local%20media%2C%0A%09iurt%20is%20suppressing%20the%20urpmi.%20cfg%20file%20while%20creating&In-Reply-To=%3C877gs7qxy5.fsf%40lebrac.rtp-net.org%3E" TITLE="[Mageia-dev] [soft-commits] [5686] For non-local media, iurt is suppressing the urpmi. cfg file while creating">arnaud.patard at rtp-net.org </A><BR> <I>Thu Sep 6 11:53:38 CEST 2012</I> <P><UL> <LI>Previous message: <A HREF="018500.html">[Mageia-dev] [soft-commits] [5686] For non-local media, iurt is suppressing the urpmi. cfg file while creating </A></li> <LI>Next message: <A HREF="018490.html">[Mageia-dev] meeting </A></li> <LI> <B>Messages sorted by:</B> <a href="date.html#18502">[ date ]</a> <a href="thread.html#18502">[ thread ]</a> <a href="subject.html#18502">[ subject ]</a> <a href="author.html#18502">[ author ]</a> </LI> </UL> <HR> <!--beginarticle--> <PRE>Thierry Vignaud <<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">thierry.vignaud at gmail.com</A>> writes: ><i> On 5 September 2012 18:05, Thierry Vignaud <<A HREF="https://www.mageia.org/mailman/listinfo/mageia-dev">thierry.vignaud at gmail.com</A>> wrote: </I>>>><i> Log Message </I>>>><i> </I>>>><i> For non-local media, iurt is suppressing the urpmi.cfg file while creating </I>>>><i> the chroot. </I>>><i> </I>>><i> Wrong, it's always removed </I>>><i> </I>>>><i> This has the side effect of forcing people to use things like </I>>>><i> --chrooted-urpmi even if the iurt configuration is fine (since it managed </I>>>><i> to create the chroot). So, add media while creating the build chroot for </I>>>><i> non-local media, as long as --chrooted-urpmi has not been used. </I>>><i> </I>>><i> Anyway this is insane IMHO: new logic is: </I>>><i> - add media </I>>><i> - install pkgs </I>>><i> - remove media </I>>><i> - readd media </I>>><i> </I>>><i> Either you should use --chrooted-urpmi (instead of re-implementing it) </I>>><i> or you should just not remove the media in the first place when using </I>>><i> use__urpmi_root, </I>>><i> aka if using remote media </I>><i> </I>><i> Ping? </I>><i> Does this patch works for your usage? </I>@@ -440,8 +428,11 @@ sub build_chroot { } # remove files used by --urpmi-root - sudo($config, "--rm", "$tmp_chroot/etc/urpmi/urpmi.cfg"); - sudo($config, "--rm", "$tmp_chroot/var/lib/urpmi/*"); + #if (!$urpmi->{use__urpmi_root} || $run->{chrooted_urpmi}) { + if (!($urpmi->{use__urpmi_root} && !$run->{chrooted_urpmi})) { + sudo($config, "--rm", "$tmp_chroot/etc/urpmi/urpmi.cfg"); + sudo($config, "--rm", "$tmp_chroot/var/lib/urpmi/*"); + } I thought about similar change too. My usage is avoiding to do something like : $ iurt --chrooted-urpmi -m core/release -- <A HREF="http://127.0.0.1/">http://127.0.0.1/</A> -r cauldron <arch> <src.rpm> when you already have this very same media in the iurt configuration. So, I guess this change will fix it. Unfortunately, it may bring troubles in some corner cases. For instance: Someone installs iurt and then creates a chroot with: $ iurt -r cauldron <arch> -c (repository url <A HREF="http://127.0.0.1/">http://127.0.0.1/</A>) Now, tries to rebuild with: $ iurt --chrooted-urpmi -m myother/release -- <A HREF="http://10.0.0.1/">http://10.0.0.1/</A> -r cauldron <arch> <src.rpm> With your proposed change, the urpmi.cfg file won't be the same. I don't know if it matters in practice but I wanted to avoid any regressions as most as possible. Arnaud </PRE> <!--endarticle--> <HR> <P><UL> <!--threads--> <LI>Previous message: <A HREF="018500.html">[Mageia-dev] [soft-commits] [5686] For non-local media, iurt is suppressing the urpmi. cfg file while creating </A></li> <LI>Next message: <A HREF="018490.html">[Mageia-dev] meeting </A></li> <LI> <B>Messages sorted by:</B> <a href="date.html#18502">[ date ]</a> <a href="thread.html#18502">[ thread ]</a> <a href="subject.html#18502">[ subject ]</a> <a href="author.html#18502">[ author ]</a> </LI> </UL> <hr> <a href="https://www.mageia.org/mailman/listinfo/mageia-dev">More information about the Mageia-dev mailing list</a><br> </body></html>