Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CC detection #334

Merged
merged 6 commits into from
Jun 20, 2023
Merged

Fix CC detection #334

merged 6 commits into from
Jun 20, 2023

Commits on Jun 13, 2023

  1. Configuration menu
    Copy the full SHA
    7f243d1 View commit details
    Browse the repository at this point in the history
  2. move .kernelvariables parsing to prepare_build()

    where the .config based compiler detection happens,
    ensures that the compiler is set for PRE_BUILD
    anbe42 committed Jun 13, 2023
    Configuration menu
    Copy the full SHA
    c53ba2c View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    3372796 View commit details
    Browse the repository at this point in the history
  4. CI: Debian: rely on the compiler dependency of the header package

    Debian (but not Ubuntu) builds its kernels with a versioned compiler
    binary (gcc-XX) and the linux-headers-* packages depend on that compiler
    anbe42 committed Jun 13, 2023
    Configuration menu
    Copy the full SHA
    3707494 View commit details
    Browse the repository at this point in the history
  5. dkms: error out if $arch cannot be determined

    if for some reason $arch cannot be determined (e.g. due to a broken rpm
    shim on distributions using a different package manager), dkms will
    happily build a module, placing state info in
    /var/lib/dkms/$module/$version/$kernel//, but that subsequently causes
    errors because the module is not considered to be installed and at the
    same time cannot be removed any more
    
    Before:
    
    sid# dkms status
    sid# ln -s /bin/true /usr/bin/rpm
    sid# dkms add dkms_test/1.0
    Creating symlink /var/lib/dkms/dkms_test/1.0/source -> /usr/src/dkms_test-1.0
    sid# dkms status
    dkms_test/1.0: added
    sid# dkms build -k 6.1.0-9-amd64 dkms_test/1.0
    Sign command: /usr/lib/linux-kbuild-6.1/scripts/sign-file
    Signing key: /var/lib/dkms/mok.key
    Public certificate (MOK): /var/lib/dkms/mok.pub
    
    Building module:
    Cleaning build area...
    make -j16 KERNELRELEASE=6.1.0-9-amd64 -C
    /lib/modules/6.1.0-9-amd64/build M=/var/lib/dkms/dkms_test/1.0/build...
    Signing module /var/lib/dkms/dkms_test/1.0/build/dkms_test.ko
    Cleaning build area...
    sid# dkms status
    dkms_test/1.0: added
    sid# dkms build -k 6.1.0-9-amd64 dkms_test/1.0
    Sign command: /usr/lib/linux-kbuild-6.1/scripts/sign-file
    Signing key: /var/lib/dkms/mok.key
    Public certificate (MOK): /var/lib/dkms/mok.pub
    Error! This module/version has already been built on: 6.1.0-9-amd64
    Directory /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64/ already exists. Use
    the dkms remove function before trying to build again.
    sid# dkms status
    dkms_test/1.0: added
    sid# dkms remove -k 6.1.0-9-amd64 dkms_test/1.0
    Module dkms_test 1.0 is not installed for kernel 6.1.0-9-amd64 ().  Skipping...
    Module dkms_test 1.0 is not built for kernel 6.1.0-9-amd64 ().  Skipping...
    sid# dkms status
    dkms_test/1.0: added
    sid# dkms remove dkms_test/1.0 --all
    sid# dkms status
    dkms_test/1.0: added
    sid# find /var/lib/dkms/dkms_test/1.0/
    /var/lib/dkms/dkms_test/1.0/
    /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64
    /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64/module
    /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64/module/dkms_test.ko
    /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64/log
    /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64/log/make.log
    /var/lib/dkms/dkms_test/1.0/6.1.0-9-amd64/log/.config
    /var/lib/dkms/dkms_test/1.0/source
    
    After:
    
    sid# dkms status
    sid# ln -s /bin/true /usr/bin/rpm
    sid# dkms add dkms_test/1.0
    Error! Could not determine architecture.
    sid# echo $?
    12
    
    to manually recover from the bug use
      rm -rf /var/lib/dkms/$module/$version
    and add/build/install the module(s) again
    anbe42 committed Jun 13, 2023
    Configuration menu
    Copy the full SHA
    f5759f4 View commit details
    Browse the repository at this point in the history

Commits on Jun 16, 2023

  1. Configuration menu
    Copy the full SHA
    bb56e9c View commit details
    Browse the repository at this point in the history