Project

General

Profile

Actions

Bug #9840

closed

[darwin] configure script fails if an empty file named `Info.plist` exists in the user's home directory

Added by pje (patrick ellis) over 10 years ago. Updated over 10 years ago.

Status:
Third Party's Issue
Assignee:
Target version:
-
ruby -v:
ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-darwin13.0]
[ruby-core:62594]

Description

On OS X 10.9.2, the ruby-2.1.2 configure script fails if an empty file named Info.plist exists in the user's home directory.

Steps to reproduce:

#!/usr/bin/env bash

touch ~/Info.plist

[[ -f ruby-2.1.2.tar.gz ]] || curl --fail -o ruby-2.1.2.tar.gz -L http://cache.ruby-lang.org/pub/ruby/2.1/ruby-2.1.2.tar.gz
[[ -d ruby-2.1.2 ]]        || tar xfz ruby-2.1.2.tar.gz

cd ruby-2.1.2

./configure

The last lines it prints before failing are:

checking whether LDFLAGS is valid... no
configure: error: something wrong with LDFLAGS=""

The generated config.log has an error message from dsymutil when validating LDFLAGS:

configure:7100: checking whether LDFLAGS is valid
configure:7113: clang -o conftest -g -O2    conftest.c  >&5
2014-05-14 12:28:59.987 dsymutil[38379:303] There was an error parsing the Info.plist for the bundle at URL Info.plist -- file:///Users/pje/
 The operation couldn’t be completed. (Cocoa error 3840.)
 <CFBasicHash 0x7fda79d013d0 [0x7fff70e21f00]>{type = immutable dict, count = 1,
entries =>
	0 : <CFString 0x7fff70e04e00 [0x7fff70e21f00]>{contents = "NSDebugDescription"} = <CFString 0x7fda79d01390 [0x7fff70e21f00]>{contents = "Cannot parse a NULL or zero-length data"}
}
configure:7113: $? = 0
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define CANONICALIZATION_FOR_MATHN 1
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define __EXTENSIONS__ 1
| #define _ALL_SOURCE 1
| #define _GNU_SOURCE 1
| #define _POSIX_PTHREAD_SEMANTICS 1
| #define _TANDEM_SOURCE 1
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:7118: result: no
configure:7120: error: something wrong with LDFLAGS=""

It looks like dsymutil is trying to read this empty plist file and fails multiple times during the configure step. It prints an error message multiple times, but only causes configure to fail during the LDFLAGS step, making it hard to debug.

Attached is config.log, which was generated from running the above code on my system.

I was able to reproduce this bug for all major ruby versions > 2.0.0.

Just for completeness's sake, here is the output of brew config from the my system:

HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew
HEAD: 724a7f84d853e978b694555ee61198c75fe409b1
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: dual-core 64-bit penryn
OS X: 10.9.2-x86_64
Xcode: 5.1.1
CLT: 5.1.0.0.1.1396320587
Clang: 5.1 build 503
X11: 2.7.5 => /opt/X11
System Ruby: 1.8.7-358
Perl: /usr/bin/perl
Python: /usr/bin/python
Ruby: /usr/bin/ruby

Files

config.log (21.1 KB) config.log pje (patrick ellis), 05/14/2014 07:30 PM
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0