macbook pro (late 2016) keyboard/touchpad support

I was able to install Leap 15 on a late 2016 macbook pro 13-inch and everything is working except the keyboard and touchpad. I found a github project that describes how to get them working, but I think it may be specific to debian based distros:

https://github.com/cb22/macbook12-spi-driver

I tried to install dkms and the kernel headers and run

sudo dkms install applespi/0.1

But I get the error:

Your kernel headers for kernel 4.12.14-lp150.11-default cannot be found at
/lib/modules/4.12.14-lp150.11-default/build or /lib/modules/4.12.14-lp150.11-default/source.

I then tried to modify the makefile to correct the kernel directory, but dkms still gives the same error and make also fails.

I am in over my head on this one and have never messed with the kernel before. Does anyone know how to get this working for openSUSE? I would hate to have to install a different distro =(

Thanks

Update:

I found another github project that has better instructions on how to get the keyboard and touch-pad working:

https://gist.github.com/roadrunner2/1289542a748d9a104e7baec6a92f9cd7

I have been able to get the keyboard and touch-pad working on Kubuntu so at least the laptop is usable now, but I am still very interested if anyone knows how to adapt this for openSUSE Leap 15.

Thanks!

I had a quick look at this.The packages required for building can be installed with…

sudo zypper install git kernel-devel dkms

The dracut-related instructions should be ok.

I think this should be ok as is…

git clone https://github.com/roadrunner2/macbook12-spi-driver.git
pushd macbook12-spi-driver
git checkout touchbar-driver-hid-driver
sudo ln -s `pwd` /usr/src/applespi-0.1
sudo dkms install applespi/0.1
popd

See how far you can get, and come back if any further advice needed or issues encountered.

Hi
@OP it would e interesting to see the 4.18 kernel and how it goes. I would suggest grabbing a live USB release of Tumbleweed and boot from that (option key when booting and select the USB device). Some of those modules already exist in this kernel…

…or maybe try the current stable kernel perhaps?
https://download.opensuse.org/repositories/Kernel:/stable/standard/

I can get to:

sudo dkms install applespi/0.1

But it fails with:

Your kernel headers for kernel 4.12.14-lp150.11-default cannot be found at
/lib/modules/4.12.14-lp150.11-default/build or /lib/modules/4.12.14-lp150.11-default/source.

I noticed this line in the make file:

KDIR := /lib/modules/$(KVERSION)/build

So I attempted to point that to /use/src/… , but I ended up with the same error when running dkms install and a bunch of different errors when trying to run make directly. I am not sure these were appropriate things to try as I have not really learned make or dkms yet…

I will try tumbleweed again… I am pretty sure I tried it briefly on accident (instead of Leap 15) and had to use a usb keyboard and mouse, but I will try a full install and then run ```zypper dup``.

I’m recommending the package called “touchegg” to get the touchpad gestures working. There is also a gui package with it called “touchegg-gui”.
Use kernel 4.18x and higher. Kernel 5.0x is coming after kernel 4.19x!!

See: https://software.opensuse.org/search?utf8=✓&q=touchegg

Add this repository to your Tumbleweed Software Manager:

https://download.opensuse.org/repositories/X11:/Unity/openSUSE_Tumbleweed/

See video at: https://github.com/JoseExposito/touchegg

Good luck!

Roman

Likely ‘kernel-default-devel’ is not installed.

I had it installed. I have the entire kernel developer pattern installed.

Trying Tumbleweed now and it hangs on “loading initial ramdisk”.

Only happening with Tumbleweed from a usb stick and not with Leap 15… not sure what is different. I tried removing the “splash=silent” in the boot config but gained no new information…

Check the Tumbleweed ISO. Are the checksums the same?

Looks good


$ sha256sum -c openSUSE-Tumbleweed-DVD-x86_64-Snapshot20180820-Media.iso.sha256 
openSUSE-Tumbleweed-DVD-x86_64-Snapshot20180820-Media.iso: OK
sha256sum: WARNING: 14 lines are improperly formatted