From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail.hytera.de ([62.157.183.118]) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1UPanN-0003QW-Q6 for ptxdist@pengutronix.de; Tue, 09 Apr 2013 17:49:18 +0200 Received: from domino.hytera.de ([172.21.102.22] helo=nbmx01.hytera.de) by mail.hytera.de with esmtp (Exim 4.72) (envelope-from ) id 1UPanH-0007ox-PR for ptxdist@pengutronix.de; Tue, 09 Apr 2013 17:49:11 +0200 MIME-Version: 1.0 Message-ID: From: Dennis.Herbrich@hytera.de Date: Tue, 9 Apr 2013 17:49:11 +0200 Subject: [ptxdist] Setting custom PTXDIST_TEMPDIR for large image gen? Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: ptxdist@pengutronix.de Greetings! I configured ptxdist 2013.03.0 to generate a rather large (8GB) hd.img for = me, but genext2fs fails: Creating root.ext2 from working = dir.../home/herbrich/AEOS2/platform-evoc-x86/sysroot-host/bin/genext2fs: = couldn't allocate a block (no free space) make: *** [/home/herbrich/AEOS2/platform-evoc-x86/images/root.ext2] Error = 1 Since I had 30+GB free space in my TOPDIR, I went into the lurking depths = of ptxdist and discovered what looked like a hardcoded setting of = PTXDIST_TEMPDIR in the setup_libs_early() function of ptxdist itself: # # source the scripts we need # # we need the PTXdist shell library # we need the version definitions # we need the static variable definitions # # out: "ptxd_*" library calls # "*" ptxdist version variables # "*DIR" directory definitions (some not correct, due to = missing PTXDIST_PLATFORMDIR) # PTXDIST_TEMPDIR generic ptxdist temp dir # setup_libs_early() { local file abs_file for file in \ scripts/ptxdist_vars.sh \ scripts/libptxdist.sh \ ; do abs_file=3D"${PTXDIST_TOPDIR}/${file}" if [ -e "${abs_file}" ]; then source "${abs_file}" || return else echo "${PTXDIST_LOG_PROMPT}FATAL didn't find = ${abs_file}" exit 1 fi done PTXDIST_TEMPDIR=3D"$(mktemp -d /tmp/ptxdist.XXXXXX)" if [ ${?} -ne 0 ]; then echo echo "${PTXDIST_LOG_PROMPT}error: unable to create = tempdir" echo exit 1 fi } Unfortunately I don't have 8+GB of RAM+swap handy, and I failed to find a = way to cleanly set this variable to a location on my HDD. In retrospect I'm glad = that kernel compilation didn't (yet) die on me with my limited /tmp ramdisk = space! So, I guess my questions are: 1. How can I reliably generate a large-ish hd.img with limited /tmp space? 2. How can I set a different PTXDIST_TEMPDIR? I am not inclined to accept "Dude, ptxdist is for embedded systems, create = a smaller image already!" as an answer, though, sorry. ;) Thanks a lot! Dennis Herbrich Hytera Mobilfunk GmbH Fritz-Hahne-Str. 7 31848 Bad M=FCnder/ Germany Abteilung E Tel.: + 49 (0) 5042 998 339 Fax: + 49 (0) 5042 998 305 mailto:dennis.herbrich@hytera.de ------------------------------------------------------------ Gesch=E4ftsf=FChrer / President: Matthias Klausing, Sitz der Gesellschaft= / = Company's Place of Business: Bad Muender, Registereintrag / Commercial = Register No. Amtsgericht / Local Court Hannover: HRB 100300, = Umsatzsteuer-Identifikationsnummer (USt-IdNr.) / VAT Identification No.: = DE 115 447 987, Elektro-Altger=E4te Register (EAR) / WEEE Register No.: DE = 187 048 87 -- = ptxdist mailing list ptxdist@pengutronix.de