Skip to Content.
Sympa Menu

sm-users - Re: [SM-Users] menuconfig for casts

sm-users AT lists.ibiblio.org

Subject: Sourcemage Users List

List archive

Chronological Thread  
  • From: Andrew <afrayedknot AT thefrayedknot.armory.com>
  • To: sm-users AT lists.ibiblio.org
  • Subject: Re: [SM-Users] menuconfig for casts
  • Date: Fri, 16 Dec 2005 18:42:59 -0800

On Fri, Dec 16, 2005 at 05:58:54PM -0200, Arthur Nascimento wrote:
> Hi!
> May I join this conversation? Since nobody else is joining I thought I
> could make myself an example and bring other lurkers into the chat.
>
> 2005/12/16, Thomas Orgis <thomas-forum AT orgis.org>:
> > But still I have to watch out for the question I want to answer
> > differently (pressed enter one time too much: redo it again)... and there
> > are these answers that are remembered in a way that I cannot change them
> > (question and answer appearing in []brackets without a prompt) - The rule
> > behind them is not so clear to me. Of course, I could look at the code to
> > find it...
>
> I agree with Thomas on every aspect so far: answering to the very same
> question a second time (or more) is definately a pain. I remember the
> last time I tried to install SMGL, on the initial rebuild, I had to
> answer 3 or 4 times if I wanted to cast gettext. Seems simple enough,
> since it stops there, but it is a real pain to reconfigure xorg over
> and over again because of so many programs depending on it.
> Also, there are those questions that just go by automatically answered
> and all I can do is restart the cast asking it to force reconfigure.
> This could be so easy with a menuconfig-like thingy to help.

I dont know when that last was, but you are *not* asked to reconfigure
xorg "over and over again". Unless you invoke cast repeatedly, or run
sorcery from like 3 years ago. A spell is processed exactly once.
Any questions, such as an optional dependency defaults to 'y' after the
first time you say so.

>
> >
> > > going on then whats just presented to the end user. All relavent spell
> > > files are shell scripts in a turing complete language, theres not really
> >
> > Wait. Yes, I already noted that spells consist of shell scripts... but
> > are they really allowed to do everything? Could a spell config script do
> > `rm -f /boot/*` ? I'd think that spell scripts (apart from install)
> > should only (be able to) access system information in a read-only way and
> > store their config/do their compilation in a confined place. And besides
> > what is allowed for them to do, what is possible in reality? Can one
> > guarantee a certain set of commands to be available to the scripts (sed,
> > perl, ...) even on a very, very minimal system? How far does the turing
> > completeness go in reality?
>
> If I may be so bold, I am quite sure Andrew doesn't really mean
> turing-complete. We all know very well what turing completeness means
> and what a universal turing machine is. I know we all are or have been
> computer science or mathematics students, but I will remind us what
> those things mean. A system is turing-complete if it can behave as an
> UTM. UTM is a machine that can do anything/everything (a computer, for
> instance). That said, I am sure sorcery isn't turing-complete, and it
> shouldn't be. Can it make complex graphics calculations, comet crash
> simulations, play emulated console games, surf the web, work as a
> server etc? We are not talking about SMGL, but about sorcery
> (cast+scribe+...); SMGL is certantly turing-complete. On a smaller
> scale, can rmdir make a dir? Can mkdir remove a dir? No, therefore
> neither is turing-complete. But can a GNU system create or remove a
> dir? Yes! Can it do those things that I asked about sorcery? Yes! The
> important question: can it behave as any other turing machine? Yes,
> therefore, it is a universal turing machine and is turing-complete.
> On some small details sorcery is turing-complete, but not on all
> points. For instance, it is necessary that the system has some sort of
> construction that allows it to loop to be t-c (the requirement is that
> it must be able to never halt, ie, reach an end). On that point almost
> everything seems t-c, but it alone cannot be the decisive point to say
> what is or is not turing-complete.

Actually I meant what I said, bash is a turing complete language. I dont
know what your definition of turing complete is, I've never heard one
talked about them this way. 'sorcery' as a program or set of programs is
not a turing complete language in it of itself, it uses a turing complete
language though. Spells are given full access to bash, which again,
is turing complete. Bash includes loops, conditionals and recursion and
random access to memory. A turing machine is simply a state machine with
access to an infinitly long linear tape a read/write head, and a mechanism
to move the tape in either direction. Believe it or not, bash, as a
programming language provides this. Although, we're insulated by the
typical programming abstractions. Note that even brainf*ck is a turing
complete language, and its only got 8 instructions.

> So to sum up, Thomas, everything has at least a little bit of turing
> completeness but only complete systems able to work as a universal
> turing machine are fully turing-complete. Besides, we all know that
> theory and practice are very different. Real machines are never turing
> machines and vice-versa so don't worry about any of this.
> I may have deviated myself from the original goal, so returning to it:
> I agree that some things are dangerous for sorcery to do. The most
> dangerous is actually 'rm -rf /home/' since the user's data is usually
> the most precious information. However, if the system is to be
> updated, them the program needs full rwx permissions to all files. It
> is only important to keep user files safe and have the option of
> whether to update config files or not, which by the way, SMGL does
> very well, I must add.

I dont think theres really a concept of "a little bit of turing
completeness". Real computers are turing machines, a cpu and its memory is
exactly what a turing machine is, its a state machine and a tape (and
yes in practice, its not infinitly long). Programming languages tend to
provide useful abstractions over a bare turing machine, or work as
several turing machines combined. However, they are still turing machines
at heart.

-Andrew


--
_________________________________________________________________________
| Andrew D. Stitt | acedit at armory.com | astitt at sourcemage.org |
| irc: afrayedknot | Sorcery Team Lead | ftp://t.armory.com/ |
| 1024D/D39B096C | 76E4 728A 04EE 62B2 A09A 96D7 4D9E 239B D39B 096C |
-------------------------------------------------------------------------




Archive powered by MHonArc 2.6.24.

Top of Page