Re: Bashism in LFS-bootscripts
Alexander E. Patrakov wrote: In /etc/rc.d/init.d/functions, we have: # if CUR_LENGTH was set to zero, then end the line if [ ${CUR_LENGTH} == 0 ]; then echo fi == is a bash-specific pattern matching operator. In this context, it should be replaced with a plain =. Or should it be: if [ $CUR_LENGTH -eq 0 ]; then instead, to do a numeric comparison? (Either with or without the quotes. It shouldn't matter unless $CUR_LENGTH might be unset.) (OTOH, is that a bashism too? I'd hope not, but I don't know for sure.) signature.asc Description: OpenPGP digital signature -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: Bashism in LFS-bootscripts
Bryan Kadzban wrote: Or should it be: if [ $CUR_LENGTH -eq 0 ]; then instead, to do a numeric comparison? (Either with or without the quotes. It shouldn't matter unless $CUR_LENGTH might be unset.) I was thinking the same thing. (OTOH, is that a bashism too? I'd hope not, but I don't know for sure.) http://www.opengroup.org/onlinepubs/009695399/utilities/test.html suggests it's standardised, so as long as the shell you're using adheres to the SUSV3 standard that construct should work just fine. Regards, Matt. -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Building LFS Without Linux/Root Access
Hi! Okay, I know, wierd subject line, but what I'm trying to accomplish is this: Currently, I build my LFS system from a set of scripts; usually, it's just a matter of a '# make lfs' before I go to sleep, and when I wake up, there's a shiny new LFS system, configured and ready to go for me. However, when there's a problem, like an incompatible new version of something on the toolchain, I get an error, and the night was wasted. So, I propose to build my LFS system on another machine, which is an SGI 64-way server running IRIX6 (mips). With parallel compiling, I'm guessing that it will cut the build time by maybe 10x. I can the tar it up, and load it on my machine. So far, I've already built gcc on it to compile some other stuff, and it's working out great. Problems: - Server is not running linux - I have no root access, and therefore no chroot access Can this still be done? What parts do I need to modify? Thanks, Michael -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: Building LFS Without Linux/Root Access
Michael Kipper wrote: Hi! Okay, I know, wierd subject line, but what I'm trying to accomplish is this: Currently, I build my LFS system from a set of scripts; usually, it's just a matter of a '# make lfs' before I go to sleep, and when I wake up, there's a shiny new LFS system, configured and ready to go for me. However, when there's a problem, like an incompatible new version of something on the toolchain, I get an error, and the night was wasted. So, I propose to build my LFS system on another machine, which is an SGI 64-way server running IRIX6 (mips). With parallel compiling, I'm guessing that it will cut the build time by maybe 10x. I can the tar it up, and load it on my machine. So far, I've already built gcc on it to compile some other stuff, and it's working out great. Problems: - Server is not running linux - I have no root access, and therefore no chroot access Can this still be done? What parts do I need to modify? Thanks, Michael You will need to look at the testing version of the cross-lfs book. You can view it at http://documents.jg555.com/cross-lfs or http://www.linuxfromscratch.org/~jhuntwork/cross-lfs -- -- [EMAIL PROTECTED] [EMAIL PROTECTED] LFS User # 2577 Registered Linux User # 299986 -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
Re: Bashism in LFS-bootscripts
Robert Russell wrote: On 5/19/05, Bryan Kadzban [EMAIL PROTECTED] wrote: We could use the enable builtin to disable the builtin versions in bash: enable -n test [ I'm (again) not sure about other shells, though... Wouldn't the binaries in /bin be used if the shell did not have builtins? Yes, but the problem would come in if there's some shell out there that does have test and [ builtins, but doesn't have an enable command that we can use to turn them off. For example, the ash(1) man page here: http://www.strw.leidenuniv.nl/cgi-bin/man?program=ashsection=1 doesn't say anything about an enable builtin in ash. It may be that there is no such builtin, which would cause problems if we did that. However, we might be able to do something with exec in a subshell instead (since exec won't run a builtin or function, only an executable): if ( exec [ -r file1 ] ) ; then do_whatever ; fi I can't decide if that's more or less ugly than: if /bin/[ -r file1 ] ; then do_whatever ; fi though. It is a few characters longer, for whatever that's worth. signature.asc Description: OpenPGP digital signature -- http://linuxfromscratch.org/mailman/listinfo/lfs-dev FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page