Skip to content

Commit

Permalink
makepkg: Only copy ntsync header over if builtin support is enabled a…
Browse files Browse the repository at this point in the history
…nd the header wasn't already installed by another package

Fixes #980
  • Loading branch information
Tk-Glitch committed Jul 22, 2024
1 parent 91e3864 commit 5b0c4b5
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -186,14 +186,14 @@ hackbase() {
# install customization file, for reference
install -Dm644 "${srcdir}"/customization-full.cfg "${pkgdir}/usr/share/doc/${pkgbase}/customization.cfg"

# workaround for missing header with ntsync
if [ -e "${_kernel_work_folder_abs}/include/uapi/linux/ntsync.h" ]; then
msg2 "Workaround missing ntsync header"
install -Dm644 "${_kernel_work_folder_abs}"/include/uapi/linux/ntsync.h "${pkgdir}/usr/include/linux/ntsync.h"
fi

# load ntsync module at boot
# ntsync
if [ -e "${srcdir}/ntsync.conf" ]; then
# workaround for missing header with ntsync
if [ -e "${_kernel_work_folder_abs}/include/uapi/linux/ntsync.h" ] && [ ! -e "/usr/include/linux/ntsync.h" ]; then
msg2 "Workaround missing ntsync header"
install -Dm644 "${_kernel_work_folder_abs}"/include/uapi/linux/ntsync.h "${pkgdir}/usr/include/linux/ntsync.h"
fi
# load ntsync module at boot
msg2 "Set the ntsync module to be loaded at boot through /etc/modules-load.d"
install -Dm644 "${srcdir}"/ntsync.conf "${pkgdir}/etc/modules-load.d/ntsync.conf"
fi
Expand Down

1 comment on commit 5b0c4b5

@ptr1337
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How does should work? The header provided by linux-api-headers is differently and provide not everything.
Maybe solve this correctly with a .install or so.

Please sign in to comment.