* ALSA and SALSA install @ 2008-03-06 16:41 Alan Horstmann 2008-03-06 16:26 ` Takashi Iwai 2008-03-06 16:46 ` Clemens Ladisch 0 siblings, 2 replies; 6+ messages in thread From: Alan Horstmann @ 2008-03-06 16:41 UTC (permalink / raw) To: Takashi Iwai; +Cc: ALSA devel Following on from thread 'Problems with ALSA in embedded device', running code such as aplay with both ALSA and SALSA libs. Is there a way to install both at the same time, so on a PC code can be compiled and experimented with first -lasound and then -lsalsa without alternately re-installing the libraries with make install? Thanks Alan ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: ALSA and SALSA install 2008-03-06 16:41 ALSA and SALSA install Alan Horstmann @ 2008-03-06 16:26 ` Takashi Iwai 2008-03-06 16:46 ` Clemens Ladisch 1 sibling, 0 replies; 6+ messages in thread From: Takashi Iwai @ 2008-03-06 16:26 UTC (permalink / raw) To: Alan Horstmann; +Cc: ALSA devel At Thu, 6 Mar 2008 16:41:33 +0000, Alan Horstmann wrote: > > Following on from thread 'Problems with ALSA in embedded device', running code > such as aplay with both ALSA and SALSA libs. > > Is there a way to install both at the same time, so on a PC code can be > compiled and experimented with first -lasound and then -lsalsa without > alternately re-installing the libraries with make install? Right now, no. SALSA-lib provides only the source-level API compatibility, not binary compatibility at all. The reason is that the binary-compatibility would expand the size of library greatly. As its name suggests, "small and spicy" is the advantage of SALSA :) Of course, it'd be welcome if someone writes a patch to add the binary-compatibility feature, but it must be still optional. BTW, I proposed SALSA in the last thread because a static library was in the question. Takashi ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: ALSA and SALSA install 2008-03-06 16:41 ALSA and SALSA install Alan Horstmann 2008-03-06 16:26 ` Takashi Iwai @ 2008-03-06 16:46 ` Clemens Ladisch 2008-03-07 20:31 ` Alan Horstmann 1 sibling, 1 reply; 6+ messages in thread From: Clemens Ladisch @ 2008-03-06 16:46 UTC (permalink / raw) To: Alan Horstmann; +Cc: Takashi Iwai, ALSA devel Alan Horstmann wrote: > Is there a way to install both at the same time, so on a PC code can be > compiled and experimented with first -lasound and then -lsalsa without > alternately re-installing the libraries with make install? It should be possible to install salsa-lib into another directory (by using the *prefix configure options) and then to change the include and library paths when compiling the program that uses it. HTH Clemens ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: ALSA and SALSA install 2008-03-06 16:46 ` Clemens Ladisch @ 2008-03-07 20:31 ` Alan Horstmann 2008-03-17 22:43 ` Alan Horstmann 0 siblings, 1 reply; 6+ messages in thread From: Alan Horstmann @ 2008-03-07 20:31 UTC (permalink / raw) To: Clemens Ladisch; +Cc: ALSA devel On Thursday 06 March 2008 16:46, Clemens Ladisch wrote: > Alan Horstmann wrote: > > Is there a way to install both at the same time, so on a PC code can be > > compiled and experimented with first -lasound and then -lsalsa without > > alternately re-installing the libraries with make install? > > It should be possible to install salsa-lib into another directory (by > using the *prefix configure options) and then to change the include > and library paths when compiling the program that uses it. > Thanks, that is the sort of thing I had hoped was possible; will try that at the next opportunity. Alan ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: ALSA and SALSA install 2008-03-07 20:31 ` Alan Horstmann @ 2008-03-17 22:43 ` Alan Horstmann 2008-03-19 15:20 ` Alan Horstmann 0 siblings, 1 reply; 6+ messages in thread From: Alan Horstmann @ 2008-03-17 22:43 UTC (permalink / raw) To: ALSA devel On Friday 07 March 2008 20:31, I wrote: > On Thursday 06 March 2008 16:46, Clemens Ladisch wrote: > > Alan Horstmann wrote: > > > Is there a way to install both at the same time, so on a PC code can be > > > compiled and experimented with first -lasound and then -lsalsa without > > > alternately re-installing the libraries with make install? > > > > It should be possible to install salsa-lib into another directory (by > > using the *prefix configure options) and then to change the include > > and library paths when compiling the program that uses it. > > Thanks, that is the sort of thing I had hoped was possible; will try that > at the next opportunity. Just to tidy off this thread, here's what I have done to achieve this. (I know it's not rocket science!) The problem is actually with the headers, not the library, as both libs exist in /usr/lib. First I manually created the salsa headers seperately in /usr/include/salsa. Then in the code put: #ifdef SALSA #include <salsa/asoundlib.h> #else #include <alsa/asoundlib.h> #endif Then on the gcc command line ... -D SALSA -lsalsa builds with salsa, or ... -lasound with standard Alsa. Is this all OK? The salsa standard install prefixes etc seemed to always put the headers under a alsa/ subdirectory. By editing salsa-lib..../src/Makefile.in L244 alsaincludedir = $(includedir)/salsa the headers are put in usr/include/salsa. I think the option of automatically installing salsa headers as above (ie / usr/include/salsa/asoundlib.h, etc) would be useful but it doesn't seem that the value of 'alsaincludedir' can be set as a configure option. Might it be worth adding it so ./configure --alsaincludedir=... is available? Alan ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: ALSA and SALSA install 2008-03-17 22:43 ` Alan Horstmann @ 2008-03-19 15:20 ` Alan Horstmann 0 siblings, 0 replies; 6+ messages in thread From: Alan Horstmann @ 2008-03-19 15:20 UTC (permalink / raw) To: Takashi Iwai; +Cc: ALSA devel [-- Attachment #1: Type: text/plain, Size: 2539 bytes --] On Monday 17 March 2008 22:43, I wrote: > On Friday 07 March 2008 20:31, Alan Horstmann wrote: > > On Thursday 06 March 2008 16:46, Clemens Ladisch wrote: > > > Alan Horstmann wrote: > > > > Is there a way to install both at the same time, so on a PC code can > > > > be compiled and experimented with first -lasound and then -lsalsa > > > > without alternately re-installing the libraries with make install? > > > > > > It should be possible to install salsa-lib into another directory (by > > > using the *prefix configure options) and then to change the include > > > and library paths when compiling the program that uses it. > > > > Thanks, that is the sort of thing I had hoped was possible; will try that > > at the next opportunity. > > Just to tidy off this thread, here's what I have done to achieve this. (I > know it's not rocket science!) The problem is actually with the headers, > not the library, as both libs exist in /usr/lib. > > First I manually created the salsa headers seperately in > /usr/include/salsa. Then in the code put: > #ifdef SALSA > #include <salsa/asoundlib.h> > #else > #include <alsa/asoundlib.h> > #endif > > Then on the gcc command line > ... -D SALSA -lsalsa > builds with salsa, or > ... -lasound > with standard Alsa. Is this all OK? > > The salsa standard install prefixes etc seemed to always put the headers > under a alsa/ subdirectory. By editing salsa-lib..../src/Makefile.in > L244 alsaincludedir = $(includedir)/salsa > the headers are put in usr/include/salsa. > > I think the option of automatically installing salsa headers as above (ie / > usr/include/salsa/asoundlib.h, etc) would be useful but it doesn't seem > that the value of 'alsaincludedir' can be set as a configure option. Might > it be worth adding it so > ./configure --alsaincludedir=... > is available? Well, I had a go at this just for interest, guessing at how to alter configure script and src/Makefile.in though I have little idea how they work. In case the principle is of any interest, the 2 attached patches enable the salsa include sub-directory to be set by configure option '--alsaincludedir=', otherwise it is (includedir)/alsa. In my case the reason is to be able to put it in (includedir)/salsa so the headers are separate. The patches are from 0.0.14 but apply to 0.0.17 OK. I am sure the alterations are not complete, and perhaps the variable should be renamed 'salsaincludedir' in this case, but that won't matter unless there is any interest in adding this option. Alan [-- Attachment #2: salsa-lib-configure-alsainclude.diff --] [-- Type: text/x-diff, Size: 2274 bytes --] --- configure-orig 2007-10-24 15:49:16.000000000 +0100 +++ configure 2008-03-18 17:05:50.000000000 +0000 @@ -787,6 +787,7 @@ sharedstatedir localstatedir includedir +alsaincludedir oldincludedir docdir infodir @@ -952,6 +953,7 @@ sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' +alsaincludedir='${prefix}/include/alsa' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE}' infodir='${datarootdir}/info' @@ -985,6 +987,10 @@ --) ac_dashdash=yes ;; + -alsaincludedir=* | --alsaincludedir=* | --alsaincludedi=* | --alsaincluded=* | --alsainclude=* \ + | --alsainclud=* | --alsainclu=* | --alsaincl=* | --alsainc=*) + alsaincludedir=$ac_optarg ;; + -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) @@ -1303,7 +1309,7 @@ # Be sure to have absolute directory names. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ - oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ + alsaincludedir oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var @@ -1451,6 +1457,7 @@ For better control, use the options below. Fine tuning of the installation directories: + --alsaincludedir=DIR alsa C header files [PREFIX/include/alsa] --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] @@ -20594,6 +20601,7 @@ sharedstatedir!$sharedstatedir$ac_delim localstatedir!$localstatedir$ac_delim includedir!$includedir$ac_delim +alsaincludedir!$alsaincludedir$ac_delim oldincludedir!$oldincludedir$ac_delim docdir!$docdir$ac_delim infodir!$infodir$ac_delim @@ -20674,7 +20682,7 @@ am__fastdepCXX_FALSE!$am__fastdepCXX_FALSE$ac_delim _ACEOF - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 98; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 [-- Attachment #3: salsa-lib-srcMakefile-alsainclude.diff --] [-- Type: text/x-diff, Size: 706 bytes --] --- src/Makefile-orig.in 2007-10-24 15:49:15.000000000 +0100 +++ src/Makefile.in 2008-03-19 14:22:58.000000000 +0000 @@ -191,6 +191,7 @@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_F77 = @ac_ct_F77@ +alsaincludedir = @alsaincludedir@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -241,7 +242,6 @@ $(am__append_2) $(am__append_3) $(am__append_4) \ $(am__append_5) $(am__append_6) libsalsa_la_LDFLAGS = -version-info 0:1:0 -alsaincludedir = $(includedir)/alsa alsainclude_HEADERS = asoundlib.h version.h recipe.h asound.h \ asoundef.h global.h input.h output.h error.h control.h \ ctl_types.h ctl_macros.h pcm.h pcm_types.h pcm_macros.h \ [-- Attachment #4: Type: text/plain, Size: 160 bytes --] _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2008-03-19 15:18 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2008-03-06 16:41 ALSA and SALSA install Alan Horstmann 2008-03-06 16:26 ` Takashi Iwai 2008-03-06 16:46 ` Clemens Ladisch 2008-03-07 20:31 ` Alan Horstmann 2008-03-17 22:43 ` Alan Horstmann 2008-03-19 15:20 ` Alan Horstmann
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.