From: Alex Young Date: 2011-06-30T07:03:45+09:00 Subject: [ruby-core:37676] [Ruby 1.9 - Bug #4946][Open] Building libruby-static.a with option nodynamic and --with-static-link-ext doesn't disable dlopen Issue #4946 has been reported by Alex Young. ---------------------------------------- Bug #4946: Building libruby-static.a with option nodynamic and --with-static-link-ext doesn't disable dlopen http://redmine.ruby-lang.org/issues/4946 Author: Alex Young Status: Open Priority: Normal Assignee: Category: build Target version: 1.9.2 ruby -v: ruby 1.9.2p180 (2011-02-18 revision 30909) [i686-linux] I uncomment option nodynamic in ext/Setup and run ./configure --with-static-link-ext, then make libruby-static.a I then compile this: /* trial.c */ #include "ruby.h" int main(){ ruby_init(); return 0; } like so: gcc -c trial.c -o trial.o -Iruby-1.9.2-p180/include -Iruby-1.9.2-p180/.ext/include/i686-linux gcc -static trial.o -Lruby-1.9.2-p180 -lruby-static -lpthread -lrt -ldl -lcrypt -lm -o trial And I see this warning: ruby-1.9.2-p180/libruby-static.a(dln.o): In function `dln_load': /home/alex/projects/scratch/ruby/ruby-1.9.2-p180/dln.c:1276: warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking I specifically do not want any run-time code loading capability, but I can see no documented way to disable dlopen; is there any way to silence this warning? -- http://redmine.ruby-lang.org