How do I install this on Mac OS X? #20

Closed
SamDecrock opened this Issue Apr 5, 2013 · 10 comments

Projects

None yet

5 participants

@SamDecrock

Hi,

I've tried everything. Can't seem to install this on Mac OS X, no .so are created when building this.

Does someone have any pointers. I'm tyring to build sink.js which uses cubeb....

@kinetiknz
Owner

Which version of OS X are you building on, and which version of XCode do you have installed?

Can you please attach a log showing the output of configure and make?

@jussi-kalliokoski
Contributor

I can confirm, I'm on OS X 10.8.3, XCode 4.6.2. For a clean build, the process went as follows:

[~] - [$] <> git clone https://github.com/kinetiknz/cubeb
Cloning into 'cubeb'...
remote: Counting objects: 917, done.
remote: Compressing objects: 100% (311/311), done.
remote: Total 917 (delta 574), reused 904 (delta 562)
Receiving objects: 100% (917/917), 234.54 KiB | 252 KiB/s, done.
Resolving deltas: 100% (574/574), done.
[~] - [$] <> cd cubeb
[~/cubeb] - [$] <master> autoreconf --install
glibtoolize: putting auxiliary files in `.'.
glibtoolize: copying file `./ltmain.sh'
glibtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
glibtoolize: copying file `m4/libtool.m4'
glibtoolize: copying file `m4/ltoptions.m4'
glibtoolize: copying file `m4/ltsugar.m4'
glibtoolize: copying file `m4/ltversion.m4'
glibtoolize: copying file `m4/lt~obsolete.m4'
configure.ac:45: installing './compile'
configure.ac:7: installing './config.guess'
configure.ac:7: installing './config.sub'
configure.ac:14: installing './install-sh'
configure.ac:14: installing './missing'
Makefile.am:4: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
Makefile.am: installing './depcomp'
parallel-tests: installing './test-driver'
[~/cubeb] - [$] <master> ./configure
checking build system type... x86_64-apple-darwin12.3.0
checking host system type... x86_64-apple-darwin12.3.0
checking target system type... x86_64-apple-darwin12.3.0
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether make supports nested variables... (cached) yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking whether gcc and cc understand -c and -o together... yes
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/local/bin/grep
checking for egrep... /usr/local/bin/grep -E
checking for fgrep... /usr/local/bin/grep -F
checking for ld used by gcc... /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld
checking if the linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm
checking the name lister (/usr/bin/nm) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 196608
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-apple-darwin12.3.0 file names to x86_64-apple-darwin12.3.0 format... func_convert_file_noop
checking how to convert x86_64-apple-darwin12.3.0 file names to toolchain format... func_convert_file_noop
checking for /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... dlltool
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... no
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm output from gcc object... ok
checking for sysroot... no
checking for mt... no
checking if : is a manifest tool... no
checking for dsymutil... dsymutil
checking for nmedit... nmedit
checking for lipo... lipo
checking for otool... otool
checking for otool64... no
checking for -single_module linker flag... yes
checking for -exported_symbols_list linker flag... yes
checking for -force_load linker flag... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... yes
checking for gcc option to produce PIC... -fno-common -DPIC
checking if gcc PIC flag -fno-common -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin12.3.0 dyld
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking how to run the C++ preprocessor... g++ -E
checking for ld used by g++... /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld
checking if the linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) is GNU ld... no
checking whether the g++ linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) supports shared libraries... yes
checking for g++ option to produce PIC... -fno-common -DPIC
checking if g++ PIC flag -fno-common -DPIC works... yes
checking if g++ static flag -static works... no
checking if g++ supports -c -o file.o... yes
checking if g++ supports -c -o file.o... (cached) yes
checking whether the g++ linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin12.3.0 dyld
checking how to hardcode library paths into programs... immediate
checking for pkg-config... /usr/local/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for PULSE... no
checking for ALSA... no
checking AudioUnit/AudioUnit.h usability... yes
checking AudioUnit/AudioUnit.h presence... yes
checking for AudioUnit/AudioUnit.h... yes
checking AudioToolbox/AudioToolbox.h usability... yes
checking AudioToolbox/AudioToolbox.h presence... yes
checking for AudioToolbox/AudioToolbox.h... yes
checking sndio.h usability... no
checking sndio.h presence... no
checking for sndio.h... no
checking SLES/OpenSLES.h usability... no
checking SLES/OpenSLES.h presence... no
checking for SLES/OpenSLES.h... no
checking android/log.h usability... no
checking android/log.h presence... no
checking for android/log.h... no
checking for mmsystem.h... no
checking for doxygen... true
checking for stdint types... stdint.h (shortcircuit)
make use of stdint.h in include/cubeb/cubeb-stdint.h (assuming C99 compatible system)
checking for ld used by gcc... (cached) /usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld
checking if the linker (/usr/llvm-gcc-4.2/libexec/gcc/i686-apple-darwin11/4.2.1/ld) is GNU ld... (cached) no
checking how to control symbol export... checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating docs/Makefile
config.status: creating docs/Doxyfile
config.status: creating cubeb.pc
config.status: creating cubeb-uninstalled.pc
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
config.status: executing libtool commands
config.status: executing include/cubeb/cubeb-stdint.h commands
config.status: creating include/cubeb/cubeb-stdint.h : _LIBCUBEB_INCLUDE_CUBEB_CUBEB_STDINT_H
[~/cubeb] - [$] <master> make
cd . && /bin/sh ./config.status config.h
config.status: creating config.h
config.status: config.h is unchanged
make  all-recursive
Making all in docs
doxygen
touch doxygen-build.stamp
  CC       src/cubeb.lo
src/cubeb.c:9:20: error: config.h: No such file or directory
make[2]: *** [src/cubeb.lo] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
[~/cubeb] - [$] <master>
@jussi-kalliokoski jussi-kalliokoski referenced this issue in jussi-kalliokoski/audiolib.js Apr 28, 2013
Closed

Install it on Mac OS X #79

@kinetiknz
Owner

config.status: creating config.h
config.status: config.h is unchanged
...
src/cubeb.c:9:20: error: config.h: No such file or directory

Is config.h actually being created, and does it have sane looking content? I still can't reproduce this with a clean pull and build, but my OS X and Xcode are slightly out of date... I'm updating them now and will retest shortly.

@kinetiknz
Owner

I can't reproduce this with Xcode 4.6.2 on 10.7, I'll try later on my 10.8 machine.

@knappe
knappe commented Apr 29, 2013

As was noted, this isn't specific to OSX.

jussi-kalliokoski/audiolib.js#73

@jussi-kalliokoski
Contributor

Is config.h actually being created, and does it have sane looking content?

config.h was missing completely, but it turns out that the problem is that diff was overwritten in my path so it wouldn't return an error code where config.status checked if config.h had changed.

Now that I changed to normal diff, everything works fine.

@SBejga
SBejga commented Jun 30, 2013

I get the following error building cubeb on Mac OS X 10.8.4:

airbox:cubeb basti [master] $ make
make  all-recursive
Making all in docs
echo "*** Warning: Doxygen not found; documentation will not be built."
*** Warning: Doxygen not found; documentation will not be built.
touch doxygen-build.stamp
  CC       src/cubeb.lo
  CC       src/cubeb_audiounit.lo
  CC       src/cubeb_audioqueue.lo
  CXXLD    src/libcubeb.la
Undefined symbols for architecture x86_64:
  "_AudioObjectGetPropertyData", referenced from:
      _audiounit_get_max_channel_count in cubeb_audiounit.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make[2]: *** [src/libcubeb.la] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

I'm tyring to build audiolib.js which uses cubeb

@knappe
knappe commented Aug 19, 2013

@kinetiknz I can duplicate @SBejga's findings:

libtool: link: g++ -dynamiclib  -o src/.libs/libcubeb.0.dylib  src/.libs/cubeb.o src/.libs/cubeb_audiounit.o src/.libs/cubeb_audioqueue.o   -framework CoreServices -framework AudioUnit -framework AudioToolbox  -pthread   -pthread -framework CoreServices -framework AudioUnit -framework AudioToolbox -install_name  /usr/local/lib/libcubeb.0.dylib -compatibility_version 1 -current_version 1.0 -Wl,-single_module -Wl,-exported_symbols_list,src/.libs/libcubeb-symbols.expsym
Undefined symbols for architecture x86_64:
  "_AudioObjectGetPropertyData", referenced from:
      _audiounit_get_max_channel_count in cubeb_audiounit.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make[2]: *** [src/libcubeb.la] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2`

I'm building on:

$ uname -v
Darwin Kernel Version 12.4.0: Wed May  1 17:57:12 PDT 2013; root:xnu-2050.24.15~1/RELEASE_X86_64
@kinetiknz
Owner

Apologies for the delay looking at this. The link errors with AudioObjectGetPropertyData and friends should be fixed in current HEAD.

@kinetiknz kinetiknz closed this Oct 2, 2013
@kinetiknz
Owner

Specifically, in commit a346795.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment