Page 1 of 1

sbcl problem

Posted: Wed Sep 29, 2010 6:59 am
by Stiv
Hello!
Sorry for my English and I'm a beginner :) .
I have a problem with weblocks and sbcl, when my friend installed sbcl I think that he didn't enable thread, so when I try to compile a program, I see this error:

Code: Select all

debugger invoked on a SIMPLE-ERROR:
  You're trying to start Weblocks on SBCL without threading
            support. Recompile your SBCL with threads enabled.
But now I don't know how I can recompile sbcl with thread enabled.

Thanks very much.
Bye!

UPDATE:

I discover this:

Code: Select all

$ port installed sbcl
The following ports are currently installed:
  sbcl @1.0.39_0+html
  sbcl @1.0.39_0+html+threads (active)
If this can be useful. Thanks :)

Re: sbcl problem

Posted: Wed Sep 29, 2010 8:28 am
by gugamilare
Either you get the source from SBCL's homepage and compile it, or you get a newer compiled binary. Newer versions of SBCL already come with thread support enabled for x86 and x86-64.

If you want to compile an older SBCL or use SBCL in another platform, you need to compile from source. Before compiling, create a file named customize-target-features.lisp inside the directory of SBCL's source with this content:

Code: Select all

    (lambda (features)
      (flet ((enable (x)
               (pushnew x features))
             (disable (x)
               (setf features (remove x features))))
        ;; Threading support.
        (enable :sb-thread)))
Then you compile SBCL. Take a look at the file base-target-features.lisp-expr for more features you may enable and the file INSTALL for general instructions.

EDIT: thread is enable by default only in Linux.

Re: sbcl problem

Posted: Wed Sep 29, 2010 10:01 am
by Stiv
Thanks for reply, I try to do this:

- Download sbcl-1.0.29-x86-darwin-binary-r2.tar.bz2
- Uncompress this file
- Created file: customize-target-features.lisp with code
- I didn't find make.sh
- so I did: "sudo sh install.sh"

but it appears the same error. :(
I'm using Mac OS with macport.

Thanks very much.
Bye

Re: sbcl problem

Posted: Wed Sep 29, 2010 11:51 am
by ramarren
Stiv wrote:I'm using Mac OS with macport.
With Macports you can build a reasonably recent version of SBCL with:

Code: Select all

port install sbcl +threads

Re: sbcl problem

Posted: Wed Sep 29, 2010 12:18 pm
by gugamilare
Stiv wrote:Thanks for reply, I try to do this:

- Download sbcl-1.0.29-x86-darwin-binary-r2.tar.bz2
- Uncompress this file
- Created file: customize-target-features.lisp with code
- I didn't find make.sh
If you didn't find make.sh it means you don't have the source with you, but a binary distribution. You have to get the source or do as Ramarren said.

Re: sbcl problem

Posted: Thu Sep 30, 2010 1:39 am
by Stiv
Ramarren wrote:
Stiv wrote:I'm using Mac OS with macport.
With Macports you can build a reasonably recent version of SBCL with:

Code: Select all

port install sbcl +threads
Thanks, I already try to do this:

Code: Select all

$ sudo port install sbcl +threads
--->  Computing dependencies for sbcl
--->  Cleaning sbcl
I didn't undestand this message.
But when I try to compile I see the same error .
I think I should change the default version of sbcl, but I do not know how to do it.

Thanks very much.
Bye!

Re: sbcl problem

Posted: Thu Sep 30, 2010 3:00 am
by ramarren
This means that you already have install SBCL from Macports, and it will not, by default rebuild only to change variants. You either have to uninstall and reinstall, or maybe do:

Code: Select all

sudo port upgrade --enforce-variants sbcl +threads

Re: sbcl problem

Posted: Thu Sep 30, 2010 3:24 am
by Stiv
Ramarren wrote:This means that you already have install SBCL from Macports, and it will not, by default rebuild only to change variants. You either have to uninstall and reinstall, or maybe do:

Code: Select all

sudo port upgrade --enforce-variants sbcl +threads
Thank you very much for the answers you are very kind and patient.

I try to do it

Code: Select all

sudo port upgrade --enforce-variants sbcl +threads
But the compile doesn't work :( ... I don't understand why.
How can I unistall and reinstall?

Thanks again.
Bye!

Re: sbcl problem

Posted: Thu Sep 30, 2010 4:13 am
by ramarren
Stiv wrote:But the compile doesn't work
In what way does it not work?
Stiv wrote:How can I unistall and reinstall?
Rather obviously

Code: Select all

sudo port uninstall sbcl
sudo port install sbcl +threads

Re: sbcl problem

Posted: Tue Oct 05, 2010 4:12 am
by Stiv
Ramarren wrote:
Stiv wrote:But the compile doesn't work
In what way does it not work?
Stiv wrote:How can I unistall and reinstall?
Rather obviously

Code: Select all

sudo port uninstall sbcl
sudo port install sbcl +threads
Thanks!
When I reinstalled sbcl I did "sudo mv sbcl.macport sbcl" and now it works.

Thanks!
Bye!