LiteSpeed Technologies
Download Download     Blog Blog     Wiki Wiki     Forum Forum     Store     Contact Contact    

Go Back   LiteSpeed Support Forums > LiteSpeed Web Server > Bug Reports > gem won't install

Reply
 
Thread Tools Display Modes
  #1  
Old 01-08-2008, 09:44 PM
brandondrew brandondrew is offline
Member
 
Join Date: Jan 2008
Posts: 17
Arrow gem won't install

The ruby-lsapi gem won't install for me.

I'm running LiteSpeed 3.3.3 Standard on OS X 10.5 (Leopard) on a MacBook (with an Intel processor, of course).

I've installed lots of gems, so as far as I know the problem is not with my system. Here's the console input and output:

Code:
DrTeeth:litespeed brandon$ sudo gem install ruby-lsapi
Bulk updating Gem source index for: http://gems.rubyforge.org
Building native extensions.  This could take a while...
ERROR:  Error installing ruby-lsapi:
        ERROR: Failed to build gem native extension.

/usr/local/bin/ruby extconf.rb install ruby-lsapi
checking for main() in -lsocket... no
creating Makefile

make
gcc -I. -I. -I/usr/local/lib/ruby/1.8/i686-darwin8.10.1 -I.  -fno-common -g -O2  -fno-common -pipe -fno-common  -c lsapilib.c
gcc -I. -I. -I/usr/local/lib/ruby/1.8/i686-darwin8.10.1 -I.  -fno-common -g -O2  -fno-common -pipe -fno-common  -c lsruby.c
cc -dynamic -bundle -undefined suppress -flat_namespace  -L"/usr/local/lib" -o lsapi.bundle lsapilib.o lsruby.o  -lruby  -lpthread -ldl -lobjc  
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libpthread.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libdl.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libobjc.dylib load command 9 unknown cmd field
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libSystem.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
/usr/bin/ld: /usr/lib/libSystem.B.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
collect2: ld returned 1 exit status
make: *** [lsapi.bundle] Error 1


Gem files will remain installed in /usr/local/lib/ruby/gems/1.8/gems/ruby-lsapi-2.9 for inspection.
Results logged to /usr/local/lib/ruby/gems/1.8/gems/ruby-lsapi-2.9/ext/lsapi/gem_make.out
DrTeeth:litespeed brandon$
It's easy to reproduce, I just type
Code:
sudo gem install ruby-lsapi
Reply With Quote
  #2  
Old 01-08-2008, 11:04 PM
brandondrew brandondrew is offline
Member
 
Join Date: Jan 2008
Posts: 17
Arrow nor will it install from souce

I tried following the directions for installing from source and it failed using that method as well. Here's my console output, to show exactly what I did:

Code:
DrTeeth:Downloads brandon$ curl -o ruby-lsapi.tgz http://www.litespeedtech.com/packages/lsapi/ruby-lsapi-2.9.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 30310  100 30310    0     0  49049      0 --:--:-- --:--:-- --:--:-- 1973k
DrTeeth:Downloads brandon$ ls ruby*
ruby-lsapi.tgz
DrTeeth:Downloads brandon$ tar -xzvf ruby-lsapi.tgz 
ruby-lsapi-2.9/
ruby-lsapi-2.9/rails/
ruby-lsapi-2.9/rails/dispatch.lsapi
ruby-lsapi-2.9/scripts/
ruby-lsapi-2.9/scripts/lsruby_runner.rb
ruby-lsapi-2.9/examples/
ruby-lsapi-2.9/examples/testlsapi.rb
ruby-lsapi-2.9/examples/testcgi.rb
ruby-lsapi-2.9/README
ruby-lsapi-2.9/ext/
ruby-lsapi-2.9/ext/lsapi/
ruby-lsapi-2.9/ext/lsapi/lsapilib.h
ruby-lsapi-2.9/ext/lsapi/lsapidef.h
ruby-lsapi-2.9/ext/lsapi/extconf.rb
ruby-lsapi-2.9/ext/lsapi/lsapilib.c
ruby-lsapi-2.9/ext/lsapi/lsruby.c
ruby-lsapi-2.9/setup.rb
DrTeeth:Downloads brandon$ cd ruby-lsapi-2.9/
DrTeeth:ruby-lsapi-2.9 brandon$ ls
README          examples        ext             rails           scripts         setup.rb
DrTeeth:ruby-lsapi-2.9 brandon$ ruby setup.rb config
---> ext
---> ext/lsapi
/usr/local/bin/ruby /Resources/Downloads/ruby-lsapi-2.9/ext/lsapi/extconf.rb
checking for main() in -lsocket... no
creating Makefile
<--- ext/lsapi
<--- ext
DrTeeth:ruby-lsapi-2.9 brandon$ ruby setup.rb setup
---> ext
---> ext/lsapi
make
gcc -I. -I. -I/usr/local/lib/ruby/1.8/i686-darwin8.10.1 -I/Resources/Downloads/ruby-lsapi-2.9/ext/lsapi  -fno-common -g -O2  -fno-common -pipe -fno-common  -c lsapilib.c
gcc -I. -I. -I/usr/local/lib/ruby/1.8/i686-darwin8.10.1 -I/Resources/Downloads/ruby-lsapi-2.9/ext/lsapi  -fno-common -g -O2  -fno-common -pipe -fno-common  -c lsruby.c
cc -dynamic -bundle -undefined suppress -flat_namespace  -L"/usr/local/lib" -o lsapi.bundle lsapilib.o lsruby.o  -lruby  -lpthread -ldl -lobjc  
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libpthread.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libdl.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libobjc.dylib load command 9 unknown cmd field
/usr/bin/ld: /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libSystem.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
/usr/bin/ld: /usr/lib/libSystem.B.dylib unknown flags (type) of section 6 (__TEXT,__dof_plockstat) in load command 0
collect2: ld returned 1 exit status
make: *** [lsapi.bundle] Error 1
setup.rb:655:in `command': system("make") failed (RuntimeError)
        from setup.rb:664:in `make'
        from setup.rb:1258:in `setup_dir_ext'
        from setup.rb:1532:in `__send__'
        from setup.rb:1532:in `traverse'
        from setup.rb:1549:in `dive_into'
        from setup.rb:1530:in `traverse'
        from setup.rb:1534:in `traverse'
        from setup.rb:1533:in `each'
         ... 8 levels...
        from setup.rb:826:in `__send__'
        from setup.rb:826:in `invoke'
        from setup.rb:773:in `invoke'
        from setup.rb:1578
DrTeeth:ruby-lsapi-2.9 brandon$

Please let me know if there's any other info I can supply that would be useful. Thanks.
Reply With Quote
  #3  
Old 01-09-2008, 08:30 AM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,590
Those errors are between ld and system libraries, so, I guess maybe your compiler environment need some special options, like building universal binary or something like that.

It will be very helpful if you can find a gem that builds native ruby extension, and post the compiling parameters used for gcc, cc, ld, etc. One pop in my head is the fcgi extension.
Reply With Quote
  #4  
Old 01-09-2008, 11:34 AM
mistwang mistwang is offline
LiteSpeed Staff
 
Join Date: May 2003
Location: New Jersey
Posts: 7,590
A possible solution:

http://discussions.apple.com/message...sageID=5888478
Reply With Quote
  #5  
Old 01-09-2008, 09:57 PM
brandondrew brandondrew is offline
Member
 
Join Date: Jan 2008
Posts: 17
Default That solved it.

Thanks! Upgrading to Xcode 3 did the trick for the gem. Now I'll see if that fixes the PHP compilation problem too.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 06:29 AM.



- Archive - Top
© Copyright 2003-2011 LiteSpeed Technologies, Inc. All rights reserved. Privacy Policy.