New Ticket     Tickets     Wiki     Browse Source     Timeline     Roadmap     Ticket Reports     Search

Ticket #26475 (closed defect: fixed)

Opened 3 years ago

Last modified 2 years ago

ruby19 failed to build: 'username_completion_function' undeclared

Reported by: christoperyeoh@… Owned by: kimuraw@…
Priority: Normal Milestone:
Component: ports Version: 1.9.1
Keywords: Cc:
Port: ruby19

Description (last modified by macsforever2000@…) (diff)

:info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_ruby19/work/ruby-1.9.2-p0" && /usr/bin/make -j2 all " returned error 2
:error:build Target org.macports.build returned: shell command failed
:debug:build Backtrace: shell command failed
    while executing
"command_exec build"
    (procedure "portbuild::build_main" line 8)
    invoked from within
"$procedure $targetname"
:info:build Warning: the following items did not execute (for ruby19): org.macports.activate org.macports.build org.macports.destroot org.macports.install
:notice:build Log for ruby19 is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_ruby19/main.log

Attachments

main.log (124.0 KB) - added by christoperyeoh@… 3 years ago.
main.log

Change History

Changed 3 years ago by christoperyeoh@…

main.log

comment:1 Changed 3 years ago by macsforever2000@…

  • Owner changed from macports-tickets@… to kimuraw@…
  • Description modified (diff)

comment:2 Changed 3 years ago by jmr@…

  • Summary changed from ruby19 failed to build to ruby19 failed to build: 'username_completion_function' undeclared

Looks like #21124.

comment:3 follow-up: ↓ 4 Changed 3 years ago by kimuraw@…

  • Status changed from new to assigned

The error wes caused by an architecture mismatch between port:readline(i386?) and port:ruby19(x86_64?).

christoperyeoh, please show me the results of the following commands.

% port installed readline
% file /opt/local/lib/libreadline.dylib

comment:4 in reply to: ↑ 3 Changed 3 years ago by christoperyeoh@…

The results follow. So I guess I installed the 64-bit version of readline in correctly?

% port installed readline

The following ports are currently installed:
  readline @6.1.002_0 (active)

% file /opt/local/lib/libreadline.dylib

/opt/local/lib/libreadline.dylib: Mach-O 64-bit dynamically linked shared library x86_64

comment:5 Changed 3 years ago by kimuraw@…

thanks. your port:readline is x86_64.

I guess

  • ran extconf.rb of ext/readline against /usr/include/readline
  • build with /opt/local/include/readline

That was strange.

I cannot reproduce this problem on my Mac. Can you try the following operations on your Mac?

(1) add an option "--with-readline-dir" to configure-args in ruby19 Portfile

% sudo port edit ruby19

Index: Portfile
===================================================================
--- Portfile  (revision 71052)
+++ Portfile  (working copy)
@@ -38,6 +38,7 @@
          port:libyaml
 
 configure.args   --enable-shared \
+         --with-readline-dir="${prefix}" \
          --mandir="${prefix}/share/man" \
          --enable-pthread \
          --without-tk \

(2) try to build ruby19

% sudo port clean ruby19
% sudo port build ruby19

If build succeed, I add the option to ruby19 Portfile of macports.org.

comment:6 Changed 3 years ago by ryandesign@…

From your log, I see:

:info:configure checking whether OS depend dynamic link works... In file included from /usr/local/include/fuse/fuse.h:26,
:info:configure                  from <command-line>:0:
:info:configure /usr/local/include/fuse/fuse_common.h:32:2: error: #error Please add -D_FILE_OFFSET_BITS=64 to your compile flags!
:info:configure In file included from /usr/local/include/fuse/fuse.h:857,
:info:configure                  from <command-line>:0:
:info:configure /usr/local/include/fuse/fuse_compat.h:69:24: error: sys/statfs.h: No such file or directory
:info:configure <built-in>:0: fatal error: when writing output to : Broken pipe

So you have files in /usr/local, which are interfering with the build. Please remove them. Having files in /usr/local while using MacPorts is not supported.

comment:7 Changed 3 years ago by kimuraw@…

I added a configure option to prefer macports' libraries in building ruby19 at r71867. I believe this change fixed your problem.

Please try the latest port:ruby19.

comment:8 Changed 2 years ago by kimuraw@…

  • Status changed from assigned to closed
  • Resolution set to fixed

I close this ticket. If your problem is not solved, you can reopen this ticket.

Note: See TracTickets for help on using tickets.