Skip to content
This repository has been archived by the owner on May 30, 2023. It is now read-only.

Static build on Linux #10413

Closed
ariya opened this issue Mar 7, 2012 · 16 comments
Closed

Static build on Linux #10413

ariya opened this issue Mar 7, 2012 · 16 comments
Milestone

Comments

@ariya
Copy link
Owner

ariya commented Mar 7, 2012

ariya.hi...@gmail.com commented:

Now that we have included Qt source (issue 226), let's investigate on how to enable static build on Linux.

Disclaimer:
This issue was migrated on 2013-03-15 from the project's former issue tracker on Google Code, Issue #413.
🌟   8 people had starred this issue at the time of migration.

@ariya
Copy link
Owner Author

ariya commented Mar 8, 2012

ariya.hi...@gmail.com commented:

Files seem to be compiled just fine. The linking is actually the main problem.

@raynor08
Copy link

rayno...@gmail.com commented:

Expecting this can be solved, that will save us huge amount of efforts by building once and deploy to all hosts!

@ariya
Copy link
Owner Author

ariya commented Mar 27, 2012

ariya.hi...@gmail.com commented:

For non-static build, deployment should not be an issue. Doesn't the deploy/package-linux-dynamic.sh script work for you?

@raynor08
Copy link

rayno...@gmail.com commented:

Yes the build.sh and package-linux-dynamic.sh work for me, and solved a runtime issue that we have on our RHEL5 and unblocked us, really appreciate the work!

The question is now with Qt/webkit source code merged to phantomJS source tree, does that mean the deployable package is all that I need to make phantomJS work on any host? And I don't have to install Qt at all on a clean host?

Thanks!

@ariya
Copy link
Owner Author

ariya commented Mar 27, 2012

ariya.hi...@gmail.com commented:

The build works everywhere, see http://ariya.ofilabs.com/2012/03/the-evolution-of-phantomjs-build-workflow.html for details. Text rendering requires Freetype and Fontconfig so those libraries must be available in the target machine.

@raynor08
Copy link

rayno...@gmail.com commented:

Got it, thanks a lot!!

@ariya
Copy link
Owner Author

ariya commented Apr 2, 2012

johan.a...@gmail.com commented:

Hi there,

We are abou to install phantomjs on REL 5.8. But it seem that the existing glibc version on the server is too old (2.5). Currently we are not able to upgrade on the servers.
What is the plan (or how do we) for providing a static build for Linux?
As said before, the static Mac OS build is perfect.

@ariya
Copy link
Owner Author

ariya commented Apr 2, 2012

ariya.hi...@gmail.com commented:

The plan is to provide a static build for Linux once someone steps in and volunteers to fix the linker problem mentioned in comment #1.

If the current binary does not work for you, I suggest trying to build from source.

@milianw
Copy link
Contributor

milianw commented Apr 27, 2012

m...@milianw.de commented:

a workaround now waits to be merged, see: #241 and https://groups.google.com/forum/#!topic/phantomjs/TVSrPVY24bs

@ariya
Copy link
Owner Author

ariya commented Apr 30, 2012

ariya.hi...@gmail.com commented:

Quasi-static patch is landed in e185a5c2b6. Thank you!

@ghost
Copy link

ghost commented Jun 27, 2012

seanerussell@gmail.com commented:

The ld-linux trick segfaults when I run it on RHEL 5.6 (quad core Opteron). I've attached a trace script.

As a test, I ran the same files the same way on Ubuntu 10.04 and I did not get a segfault. FWIW, I tried running it with RHEL's ld-linux; it failed with a symbol lookup error in GLIBCXX.

@ghost
Copy link

ghost commented Jun 27, 2012

seanerussell@gmail.com commented:

setarch doesn't help:

[russes02a@ybkoperl53t autocompare]$ setarch x86_64 -RL ./phantomjs-1.5.0/lib/ld-linux-x86-64.so.2 --library-path ./phantomjs-1.5.0/lib phantomjs-1.5.0/bin/phantomjs
Segmentation fault

Sadness.

@ariya
Copy link
Owner Author

ariya commented Jul 15, 2012

ariya.hi...@gmail.com commented:

 

 
Metadata Updates

  • Milestone updated: Release1.7 (was: FutureRelease)

@ariya
Copy link
Owner Author

ariya commented Jul 15, 2012

ariya.hi...@gmail.com commented:

Landed in 31157fb.

 
Metadata Updates

@ariya ariya closed this as completed Jul 15, 2012
@trichins
Copy link

trich...@soleranetworks.com commented:

The run script doesn't work. The last line is written as:

exec $path/lib/ld-linux-x86-64.so.2 $phantomjs $@

when it should instead be:
exec $path/lib/ld-linux-x86-64.so.2 $path/bin/phantomjs.bin $@

@ariya
Copy link
Owner Author

ariya commented Feb 17, 2013

jzx...@gmail.com commented:

Could you tell me if the build script still capable of producing a dynamic build, if so how ?

I used to favor static build too. but on a low end 256M device with no swap. Phantom is bearly usable other than opening "example.com", suffering frequent resource allocation error. On the other hand, Ghost.py with PyQt4 works just fine with. I wonder if this is due to the static build nature.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants