Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

How to set CFLAGS when building kernel

Featured Replies

I am trying to build the kernel with the standards scripts, but directly on my orange pi 5.

The build is stopping at some point because of a Warning issued by the compiler (this is the default behaviour for the compiler who does not tolerate any warning by default).

(Some functions in the C code are depreciated, thus a warning is issue)

 

How can I set the CFLAGS so that the kernel build takes it into account during compilation?

 

Thanks.

  • Author

I keep getting this error

  LD [M]  drivers/net/wireless/rockchip_wlan/rtl8852bu/8852bu.o
scripts/extract-cert.c: In function ‘display_openssl_errors’:
scripts/extract-cert.c:46:9: warning: ‘ERR_get_error_line’ is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
   46 |         while ((e = ERR_get_error_line(&file, &line))) {
 

IS there a way to disable the warning becoming errors?

I tried   CONFIG_WERROR=no  but it has no effect.

 

 

My experience is that it's showing that warning when there is an error. So that warning is not the reason it stopped, I would think it's an error with 8852bu.c.

It seems that the error log messages is/will be better with the "next" branch

Set the options in the kernel configure menu:

./compile.sh BUILD_ONLY=kernel KERNEL_CONFIGURE=yes BOARD=orangepi5 BRANCH=legacy

Edited by royk

  • Author

Indeed it was a problem with the 8852bu.c, but not only,  to compile successfully I had to deselect all the realtek wifi drivers, in particular the rtl8188eu.

 

I finally got my kernel generated...yeaahhhhh!

However, I can see the generated files in the output/debs directory, but not sure what to do with them?

I only want to install my new kernel, not u-boot, not the full image, how shall I proceed?

 

I read lots of things on the net:

   run armbian-pdate

   run dpkg -i *.debs

   run dpkg -i newkernel.deb

......

 

How shall I proceed? How will the modules be updated? With the dpkg -i and only one deb file?

 

I have not found the official documentation from armbian.doc about what to do after the build finished, did I miss something?

 

Thanks again.

 

4 часа назад, Tony3 сказал:

I have not found the official documentation

You have to transfer two files (linux-dtb*linux-image*) to the system on the device. It can be mc & ssh or just write them to the home directory on the sd card from which the device is loaded.

Sorry. I didn't see that build directly on the device.

 

If the build was done using the scripts of the Armbian build system, then just install two packages

 using the "dpkg -i linux-dtb-*.deb linux-image-*.deb " command.

Edited by going
Fixed

I've seen there is a commit on the GitHub about the WiFi adapters, perhaps they will compile after updating your git directory. To install the kernel you could type sudo apt install ./*.deb but sometimes won't "re" install as it's the same version, which you could force however. Usually I do sudo dpkg -i *.deb

 

@going Few questions, why do you need to transfer these files? As backup before you do a second compile? 

Isn't it necessary to install the source when they got patched? With mc you mean nc?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.