Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Need help with a patch for the Alsa UCM bug.
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
assemblerhead
n00b
n00b


Joined: 23 Jan 2016
Posts: 28
Location: TX,US

PostPosted: Sat May 11, 2024 3:19 pm    Post subject: Need help with a patch for the Alsa UCM bug. Reply with quote

Followed the Gentoo patch gen guide at wiki.gentoo.org/wiki/creating_a_patch.
Cannot get the ebuild in the local/testing overlay to use it.

I am using links for a browser / cannot get a working -pipewire/pulseaudio- without a working Alsa UCM.

CMD : alsaucm listcards
Response : listisempty
Alsa lost its UCM config path:/usr/share/alsa
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54391
Location: 56N 3W

PostPosted: Sat May 11, 2024 3:30 pm    Post subject: Reply with quote

assemblerhead,

Tells us what you patched and what the error is when you try to use it.
Post the patch if it helps.

You cannot apply a batch to the ebuild itself. Instead copy it to your local overlay and edit it there.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
assemblerhead
n00b
n00b


Joined: 23 Jan 2016
Posts: 28
Location: TX,US

PostPosted: Sat May 11, 2024 5:32 pm    Post subject: requested info Reply with quote

file patched /src/ucm/makefile.am
Line added under : AM_CPPFLAGS=-I($top_srcdir)/include
Line added : AM_CPPFLAGS=-I/usr/share/alsa
placed the patch in the files dir, for the overlay.
Error :
* Applying alsa-lib-1.1.6-missing_files.patch ... [ ok ]
* Applying alsa-lib-1.2.11-topology-correct-version-script-path.patch ... [ ok ]
* Applying alsa-lib-1.2.11-lost-ucm-config-path.patch ...
can't find file to patch at input line 5
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/alsa-lib-1.2.11/src/ucm/Makefile.am b/alsa-lib-1.2.11/src/ucm/Makefile.am
|index 7108968..ef84ef0 100644
|--- a/alsa-lib-1.2.11/src/ucm/Makefile.am
|+++ b/alsa-lib-1.2.11/src/ucm/Makefile.am
--------------------------
Back to top
View user's profile Send private message
assemblerhead
n00b
n00b


Joined: 23 Jan 2016
Posts: 28
Location: TX,US

PostPosted: Sat May 11, 2024 5:47 pm    Post subject: Reply with quote

file patched: /src/ucm/makefiles.am
Error :
* Applying alsa-lib-1.2.11-topology-correct-version-script-path.patch ... [ ok ]
* Applying alsa-lib-1.2.11-lost-ucm-config-path.patch ...
can't find file to patch at input line 5
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/alsa-lib-1.2.11/src/ucm/Makefile.am b/alsa-lib-1.2.11/src/ucm/Makefile.am
|index 7108968..ef84ef0 100644
|--- a/alsa-lib-1.2.11/src/ucm/Makefile.am
|+++ b/alsa-lib-1.2.11/src/ucm/Makefile.am
--------------------------
No file to patch. Skipping patch.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54391
Location: 56N 3W

PostPosted: Sun May 12, 2024 1:53 pm    Post subject: Reply with quote

assemblerhead,
te patch.
Portage can't find the file
Code:
alsa-lib-1.2.11/src/ucm/Makefile.am
to patch.
Its using
Code:
patch -p1 a/alsa-lib-1.2.11/src/ucm/Makefile.am
the -p1 throws away the first path element, here a/

Code:
>>> Preparing source in /var/tmp/portage/media-libs/alsa-lib-1.2.11/work/alsa-lib-1.2.11 ...
 * Applying alsa-lib-1.1.6-missing_files.patch ...                       [ ok ]
 * Applying alsa-lib-1.2.11-topology-correct-version-script-path.patch . [ ok ]
 * Running eautoreconf in '/var/tmp/portage/media-libs/alsa-lib-1.2.11/work/alsa-lib-1.2.11' ...


The full path to the file you want to patch is
Code:
/var/tmp/portage/media-libs/alsa-lib-1.2.11/work/alsa-lib-1.2.11/src/ucm/Makefile.am

Your patch path looks correct.

Can you apply the patch manually?
Code:

ebuild /var/db/repos/gentoo/media-libs/alsa-lib/alsa-lib-1.2.11.ebuild prepare
cd /var/tmp/portage/media-libs/alsa-lib-1.2.11/work
patch -p1 <path_to_patch_file>


The ebuild command runs the unpack and prepare phase functions, then gives you control back.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
grknight
Retired Dev
Retired Dev


Joined: 20 Feb 2015
Posts: 1698

PostPosted: Sun May 12, 2024 2:33 pm    Post subject: Reply with quote

NeddySeagoon wrote:
Portage can't find the file
Code:
alsa-lib-1.2.11/src/ucm/Makefile.am
to patch.
Its using
Code:
patch -p1 a/alsa-lib-1.2.11/src/ucm/Makefile.am
the -p1 throws away the first path element, here a/

The full path to the file you want to patch is
Code:
/var/tmp/portage/media-libs/alsa-lib-1.2.11/work/alsa-lib-1.2.11/src/ucm/Makefile.am

Your patch path looks correct.

I will disagree here.

src_prepare, where eapply_user is run, starts by changing to $S. Here, $S=/var/tmp/portage/media-libs/alsa-lib-1.2.11/work/alsa-lib-1.2.11
So the patch must be a/src/ucm/Makefile.am and b/src/ucm/Makefile.am in its headers to be compatible with -p1.
Back to top
View user's profile Send private message
assemblerhead
n00b
n00b


Joined: 23 Jan 2016
Posts: 28
Location: TX,US

PostPosted: Mon May 13, 2024 7:38 pm    Post subject: Thanks for the info, got it partly working Reply with quote

A new error. GCC crashes when it hits my added "-I/usr/share/alsa".
--file not found : ucm_local.h--

How do I inform alsa-lib where their ucm config files are?

Can't use absolute pathing in CPP includes per GCC manuel.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum