Discussion:
make-speakup-kernel
John G Heim
2016-08-10 15:51:32 UTC
Permalink
I posted an updated version of the script I use to build the kernel
hacked to support serial hardware synths. This script does everything
necessary to build a kernel for either debian or ubuntu. Even if you
don't want to use the script, it might be educational for learning to
build the kernel yourself. To download the script:


wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
--
John G. Heim; ***@math.wisc.edu; sip://***@sip.linphone.org
Jude DaShiell
2016-08-11 01:21:26 UTC
Permalink
Will this script work for gentoo? That distro seriously needs a good
script to do something like this.
Date: Wed, 10 Aug 2016 11:51:32
Subject: make-speakup-kernel
I posted an updated version of the script I use to build the kernel
hacked to support serial hardware synths. This script does everything
necessary to build a kernel for either debian or ubuntu. Even if you
don't want to use the script, it might be educational for learning to
wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
c***@ccs.covici.com
2016-08-11 01:59:17 UTC
Permalink
I just patch and recompile, using gentoo since you have to compile
anyway, I never bothered to write a script. You may also have to patch
serialio.h unless the kernel has it already.
Post by Jude DaShiell
Will this script work for gentoo? That distro seriously needs a good
script to do something like this.
Date: Wed, 10 Aug 2016 11:51:32
Subject: make-speakup-kernel
I posted an updated version of the script I use to build the kernel
hacked to support serial hardware synths. This script does
everything necessary to build a kernel for either debian or
ubuntu. Even if you don't want to use the script, it might be
educational for learning to build the kernel yourself. To download
wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
_______________________________________________
Speakup mailing list
http://linux-speakup.org/cgi-bin/mailman/listinfo/speakup
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?

John Covici
***@ccs.covici.com
John G Heim
2016-08-11 14:10:47 UTC
Permalink
The script would not work for gentoo as written. It relies on
"lsb_release -si" returning either "Debian" or "Ubuntu". I have been
making progress on making it more general but it is very difficult even
to write a script that works from one release of debian to the next or
from one release of ubuntu to the next. For example, when you download
the kernel source package, it creates a subdirectory of your current
working directory. That directory name is not the same from release to
release, and in fact, I've found that the pattern for the name of that
subdirectory isn't consistent from one release to the next. I had code
to determine the subdir name based on the output from uname but it
didn't work when I upgraded my PC. I figured out a way around that. But
another problem is that the patch itself is very specific to a
particular kernel version.

I see that gentoo compiles all of it's packages on your computer. All
you would need to do is hack the code yourself before it compiles the
kernel. You need to edit the file drivers/staging/serialio.c in the
kernel source tree. Find a line that issues a warning saying "Unable to
allocate port at" and comment out the return statement after that
warning. My patch files also change that warning to say "continuing
anyway". That makes it easier to see what is happening in the system
logs. My kernel build script also adds the string "+spk" to the kernel
version to make it easier for you to tell which kernel you are running
via the uname command. I have no idea how to do that in gentoo.
Post by Jude DaShiell
Will this script work for gentoo? That distro seriously needs a good
script to do something like this.
Date: Wed, 10 Aug 2016 11:51:32
To: Speakup is a screen review system for Linux.
Subject: make-speakup-kernel
I posted an updated version of the script I use to build the kernel
hacked to support serial hardware synths. This script does everything
necessary to build a kernel for either debian or ubuntu. Even if you
don't want to use the script, it might be educational for learning to
wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
--
John G. Heim; ***@math.wisc.edu; sip://***@sip.linphone.org
c***@ccs.covici.com
2016-08-11 14:25:34 UTC
Permalink
In gentoo you would have to change the makefile directly in the
additional version or whatever its called.
Post by John G Heim
The script would not work for gentoo as written. It relies on
"lsb_release -si" returning either "Debian" or "Ubuntu". I have been
making progress on making it more general but it is very difficult
even to write a script that works from one release of debian to the
next or from one release of ubuntu to the next. For example, when you
download the kernel source package, it creates a subdirectory of your
current working directory. That directory name is not the same from
release to release, and in fact, I've found that the pattern for the
name of that subdirectory isn't consistent from one release to the
next. I had code to determine the subdir name based on the output from
uname but it didn't work when I upgraded my PC. I figured out a way
around that. But another problem is that the patch itself is very
specific to a particular kernel version.
I see that gentoo compiles all of it's packages on your computer. All
you would need to do is hack the code yourself before it compiles the
kernel. You need to edit the file drivers/staging/serialio.c in the
kernel source tree. Find a line that issues a warning saying "Unable
to allocate port at" and comment out the return statement after that
warning. My patch files also change that warning to say "continuing
anyway". That makes it easier to see what is happening in the system
logs. My kernel build script also adds the string "+spk" to the
kernel version to make it easier for you to tell which kernel you are
running via the uname command. I have no idea how to do that in
gentoo.
Post by Jude DaShiell
Will this script work for gentoo? That distro seriously needs a
good script to do something like this.
Date: Wed, 10 Aug 2016 11:51:32
To: Speakup is a screen review system for
Subject: make-speakup-kernel
I posted an updated version of the script I use to build the kernel
hacked to support serial hardware synths. This script does
everything necessary to build a kernel for either debian or
ubuntu. Even if you don't want to use the script, it might be
educational for learning to build the kernel yourself. To download
wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
--
_______________________________________________
Speakup mailing list
http://linux-speakup.org/cgi-bin/mailman/listinfo/speakup
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?

John Covici
***@ccs.covici.com
Jude DaShiell
2016-08-12 04:18:31 UTC
Permalink
The problem about finding the new subdirectory name should be pretty
trivial to handle it's just a matter of as adventurers would tell you
using the right door. Maybe this will help.
If a script runs and collects all existing subdirectory names then saves
them to an array or data base then tells the user to download the kernel
package and after that to run a second script that's included once they
have downloaded the kernel source. The second script would make a
second data base with a different name if the first data base the first
script ought to have made was found and that second data base would
again collect all existing subdirectory names. Once done a compare
which eliminates common subdirectories in both data bases would happen
and all you're left with is the path to the new kernel source in the
second data base. I hope this helps.
Date: Thu, 11 Aug 2016 10:10:47
Subject: Re: make-speakup-kernel
The script would not work for gentoo as written. It relies on "lsb_release
-si" returning either "Debian" or "Ubuntu". I have been making progress on
making it more general but it is very difficult even to write a script that
works from one release of debian to the next or from one release of ubuntu to
the next. For example, when you download the kernel source package, it
creates a subdirectory of your current working directory. That directory name
is not the same from release to release, and in fact, I've found that the
pattern for the name of that subdirectory isn't consistent from one release
to the next. I had code to determine the subdir name based on the output from
uname but it didn't work when I upgraded my PC. I figured out a way around
that. But another problem is that the patch itself is very specific to a
particular kernel version.
I see that gentoo compiles all of it's packages on your computer. All you
would need to do is hack the code yourself before it compiles the kernel. You
need to edit the file drivers/staging/serialio.c in the kernel source tree.
Find a line that issues a warning saying "Unable to allocate port at" and
comment out the return statement after that warning. My patch files also
change that warning to say "continuing anyway". That makes it easier to see
what is happening in the system logs. My kernel build script also adds the
string "+spk" to the kernel version to make it easier for you to tell which
kernel you are running via the uname command. I have no idea how to do that
in gentoo.
Post by Jude DaShiell
Will this script work for gentoo? That distro seriously needs a good
script to do something like this.
Date: Wed, 10 Aug 2016 11:51:32
To: Speakup is a screen review system for Linux.
Subject: make-speakup-kernel
I posted an updated version of the script I use to build the kernel hacked
to support serial hardware synths. This script does everything necessary
to build a kernel for either debian or ubuntu. Even if you don't want to
use the script, it might be educational for learning to build the kernel
wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
Tony Baechler
2017-05-04 12:06:03 UTC
Permalink
All,

Again, sorry for replying to a very old thread. With the recent Speakup
patches, here are my quick steps to compiling a kernel for Debian, Ubuntu
and derivatives. The generated image installed fine here, but as always, use
at your own risk.

1. Download the "linux-source" package for the version you want, such as
4.10.7 as the time of writing:

http://deb.debian.net/debian/pool/main/l/linux/

2. Install the package:

sudo -i linux-source-4.10.7*.deb

3. If not already installed, make sure you install build-essential:

sudo apt-get -q install build-essential

You probably want to install recommended packages.

4. Make a directory in your home directory and extract the source:

cd
mkdir kernel
cd kernel
tar xf /usr/src/linux-source-XXX.tar.xz

Replace XXX with the full name of the tar archive found in /usr/src. All
recent linux-source packages have an identical naming convention. It will
extract a full kernel source archive with Debian patches.

5. Copy a config file. You can use the one in /boot if your kernel is recent
enough. Otherwise, under /usr/src, you'll find a config-4.10.7 directory
with various files. In my case, I copy *amd64 to .config in the top level
kernel source directory, such as ~/kernel/.config.

Apply any patches you want, such as the new speakup2.tgz archive over the
Speakup code supplied with the kernel. When everything is done, just run this:

make deb-pkg

You probably want to append a custom version string. Details on how to do
that and a fuller explanation of the above can be found here in section 8.10:

https://debian-handbook.info/browse/stable/

Hopefully the above is useful. I release this document into the public
domain, but credit would be appreciated. Please credit Baechler Access
Technology Services. Thanks.
The script would not work for gentoo as written. It relies on "lsb_release
-si" returning either "Debian" or "Ubuntu". I have been making progress on
making it more general but it is very difficult even to write a script that
works from one release of debian to the next or from one release of ubuntu
to the next. For example, when you download the kernel source package, it
creates a subdirectory of your current working directory. That directory
name is not the same from release to release, and in fact, I've found that
the pattern for the name of that subdirectory isn't consistent from one
release to the next. I had code to determine the subdir name based on the
output from uname but it didn't work when I upgraded my PC. I figured out a
way around that. But another problem is that the patch itself is very
specific to a particular kernel version.
I see that gentoo compiles all of it's packages on your computer. All you
would need to do is hack the code yourself before it compiles the kernel.
You need to edit the file drivers/staging/serialio.c in the kernel source
tree. Find a line that issues a warning saying "Unable to allocate port at"
and comment out the return statement after that warning. My patch files also
change that warning to say "continuing anyway". That makes it easier to see
what is happening in the system logs. My kernel build script also adds the
string "+spk" to the kernel version to make it easier for you to tell which
kernel you are running via the uname command. I have no idea how to do that
in gentoo.
Post by Jude DaShiell
Will this script work for gentoo? That distro seriously needs a good
script to do something like this.
Date: Wed, 10 Aug 2016 11:51:32
Subject: make-speakup-kernel
I posted an updated version of the script I use to build the kernel
hacked to support serial hardware synths. This script does everything
necessary to build a kernel for either debian or ubuntu. Even if you
don't want to use the script, it might be educational for learning to
wget http://www.iavit.org/~john/Debian/make-speakup-kernel
--
James 5:16 Confess therefore your sins one to another, and pray one for
another, that ye may be healed. The supplication of a righteous man
availeth much in its working. (ASV)
Loading...