Skip to content
This repository has been archived by the owner on Nov 27, 2017. It is now read-only.

brew install svn failed #21

Closed
huahang opened this issue Aug 14, 2013 · 10 comments
Closed

brew install svn failed #21

huahang opened this issue Aug 14, 2013 · 10 comments
Assignees
Labels

Comments

@huahang
Copy link
Contributor

huahang commented Aug 14, 2013


Libraries have been installed in:
/home/huahang/.linuxbrew/Cellar/subversion/1.8.1/lib

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:

  • add LIBDIR to the `LD_LIBRARY_PATH' environment variable
    during execution
  • add LIBDIR to the `LD_RUN_PATH' environment variable
    during linking
  • use the `-Wl,-rpath -Wl,LIBDIR' linker flag
  • have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentation about shared libraries for

more information, such as the ld(1) and ld.so(8) manual pages.

==> Configuration
HOMEBREW_VERSION: 0.9.4
HEAD: f4e8491
HOMEBREW_PREFIX: /home/huahang/.linuxbrew
CPU: quad-core 64-bit dunno
OS X: 0-x86_64
X11: N/A
==> ENV
CC: /usr/bin/gcc => /usr/bin/gcc-4.6
CXX: /usr/bin/g++ => /usr/bin/g++-4.6
CFLAGS: -Os -w -pipe -march=core2 -msse4
CXXFLAGS: -Os -w -pipe -march=core2 -msse4
CPPFLAGS: -I/home/huahang/.linuxbrew/opt/sqlite/include -I/home/huahang/.linuxbrew/opt/readline/include -isystem /home/huahang/.linuxbrew/include
LDFLAGS: -L/home/huahang/.linuxbrew/opt/sqlite/lib -L/home/huahang/.linuxbrew/opt/readline/lib -L/home/huahang/.linuxbrew/lib
MAKEFLAGS: -j4
CMAKE_PREFIX_PATH: /home/huahang/.linuxbrew/opt/sqlite:/home/huahang/.linuxbrew/opt/readline:/home/huahang/.linuxbrew
PKG_CONFIG_PATH: /home/huahang/.linuxbrew/opt/sqlite/lib/pkgconfig
PKG_CONFIG_LIBDIR: /home/huahang/.linuxbrew/lib/pkgconfig:/usr/lib/pkgconfig
ACLOCAL_PATH: /home/huahang/.linuxbrew/share/aclocal
OBJC: /usr/bin/gcc
PATH: /home/huahang/.linuxbrew/opt/sqlite/bin:/home/huahang/.jenv/bin:/home/huahang/.linuxbrew/bin:/home/huahang/Applications/pidcat:/home/huahang/Applications/android-ndk-r8e:/home/huahang/Applications/android-sdk/platform-tools:/home/huahang/Applications/android-sdk/tools:/home/huahang/Applications/phabricator/arcanist/bin:/home/huahang/Applications/hadoop-2.0.0-mdh1.2.0-SNAPSHOT/bin:/zfs/Applications/jdk1.6.0_45/bin:/home/huahang/bin:/home/huahang/.jenv/bin:/home/huahang/.jenv/candidates/scala/current/bin:/home/huahang/.jenv/candidates/sbt/current/bin:/home/huahang/.jenv/candidates/maven/current/bin:/home/huahang/.jenv/candidates/java/current/bin:/home/huahang/.jenv/candidates/gradle/current/bin:/home/huahang/Applications/pidcat:/home/huahang/Applications/android-ndk-r8e:/home/huahang/Applications/android-sdk/platform-tools:/home/huahang/Applications/android-sdk/tools:/home/huahang/Applications/phabricator/arcanist/bin:/home/huahang/Applications/hadoop-2.0.0-mdh1.2.0-SNAPSHOT/bin:/zfs/Applications/jdk1.6.0_45/bin:/home/huahang/bin:/home/huahang/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/huahang/.linuxbrew/Library/Contributions/cmd

@sjackman
Copy link
Member

I don't see the actual error message in the text that you've included, which is the standard boiler-plate text for a keg-only install.

@mistydemeo
Copy link
Contributor

Can you provide the full logs in a gist?

svn is not keg-only - @sjackman, do you know why that would print?

@sjackman
Copy link
Member

I believe if symlinking fails, that message will print.

@sjackman
Copy link
Member

For example, if SVN is already installed in /usr/local outside of Homebrew.

@jacknagel
Copy link
Contributor

That text comes from libtool, not Homebrew.

@sjackman
Copy link
Member

Ah, thanks for clearing that up, Jack.

@tokiloki
Copy link

For brew install svn at first I get this error

==> Installing subversion dependency: serf
==> Downloading http://serf.googlecode.com/files/serf-1.2.1.tar.bz2
######################################################################## 100,0%
==> ./configure --prefix=/home/vv/linuxbrew/Cellar/serf/1.2.1 --with-apr=/usr/bin
checking target system type... i686-pc-linux-gnu

Configuring Apache Portable Runtime library...

checking for APR... configure: error: the --with-apr parameter is incorrect. It must specify an install prefix, a     build directory, or an apr-config file.

READ THIS: https://github.com/mxcl/homebrew/wiki/troubleshooting

These open issues may also help:
    https://github.com/mxcl/homebrew/pull/21427
    https://github.com/mxcl/homebrew/pull/21449

Which can be fixed by

diff --git a/Library/Formula/serf.rb b/Library/Formula/serf.rb
index 2eea834..3d9bfc1 100644
--- a/Library/Formula/serf.rb
+++ b/Library/Formula/serf.rb
@@ -10,8 +10,13 @@ class Serf < Formula
   depends_on :libtool
   depends_on 'sqlite'

+  if not MACOS
+    depends_on 'apr'
+    depends_on 'apr-util'
+  end
+
   def apr_bin
-    superbin or "/usr/bin"
+    superbin or Formula.factory('apr').opt_prefix
   end

   def install

Another problem is fixed here Homebrew/legacy-homebrew@db1f06f#Library/Formula/subversion.rb

Then problem is

==> ./configure --prefix=/home/vv/linuxbrew/Cellar/subversion/1.8.0 --with-apr=/usr/bin --with-zlib=/usr --with-    sqlite=/home/vv/linuxbrew/opt/sqlite --with-serf=/home/vv/linuxbrew/opt/serf --di
checking for egrep... /bin/grep -E
checking whether ln -s works... yes
checking for a BSD-compatible install... /usr/bin/install -c
configure: Apache Portable Runtime (APR) library configuration
checking for APR... configure: error: the --with-apr parameter is incorrect. It must specify an install prefix, a build directory, or an apr-config file.

which is fixed by

diff --git a/Library/Formula/subversion.rb b/Library/Formula/subversion.rb
index 53020a2..acaa8d1 100644
--- a/Library/Formula/subversion.rb
+++ b/Library/Formula/subversion.rb
@@ -53,7 +53,7 @@ class Subversion < Formula
   end if (build.include? 'perl') or (build.include? 'ruby')

   def apr_bin
-    superbin or "/usr/bin"
+    superbin or Formula.factory('apr').opt_prefix
   end

   def install

@ghost ghost assigned sjackman Aug 29, 2013
@sjackman
Copy link
Member

Dependencies that are included with Mac OS X are not listed as dependencies in Homebrew formulae. It'd be great if they were, but we'd need to sort with the mxcl/homebrew folk how to best go about that. In the mean time, I suggest installing APR with your native package manager (apt-get or yum).

Cheers,
Shaun

@paulhybryant
Copy link
Contributor

Hi,

I ran into exactly the same issue originally reported.
I didn't see anything related to keg-only in the formular.
And the library and binary do not existing in Cellar directory.

The gist log is here https://gist.github.com/anonymous/dff6ff729d44d1a85534

Thanks,

@sjackman
Copy link
Member

https://gist.github.com/anonymous/dff6ff729d44d1a85534#file-05-make-L128-L133

libtool: warning: relinking 'libsvn_delta-1.la'
libtool: install: (cd /tmp/subversion-JCJW8L/subversion-1.8.11/subversion/libsvn_delta; /bin/bash "/tmp/subversion-JCJW8L/subversion-1.8.11/libtool"  --tag CC --silent --mode=relink /home/yu/.linuxbrew/bin/gcc-4.9 -Os -w -pipe -march=core2 -pthread -DNDEBUG -L/home/yu/.linuxbrew/lib -Wl,-rpath,/home/yu/.linuxbrew/lib -L/home/yu/.linuxbrew/Cellar/subversion/1.8.11/libexec/serf/lib -rpath /home/yu/.linuxbrew/Cellar/subversion/1.8.11/lib -version-info 0 -Wl,--no-undefined -o libsvn_delta-1.la cancel.lo compat.lo compose_delta.lo debug_editor.lo default_editor.lo deprecated.lo depth_filter_editor.lo editor.lo path_driver.lo svndiff.lo text_delta.lo version.lo xdelta.lo ../../subversion/libsvn_subr/libsvn_subr-1.la -L/home/yu/.linuxbrew/Cellar/apr-util/1.5.4/libexec/lib -laprutil-1 -L/home/yu/.linuxbrew/Cellar/apr/1.5.1/libexec/lib -lapr-1 -lz )
/usr/bin/ld: cannot find -lsvn_delta-1
collect2: error: ld returned 1 exit status
libtool:   error: error: relink 'libsvn_ra_serf-1.la' with the above command before installing it
make: *** [install-serf-lib] Error 1

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

No branches or pull requests

6 participants