Jump to content

ArmBian Kernel for OdroidXU4 is failing to compile with -C KERNEL_SOURCES O=SOMEWHERE_ELSE option


EasyNet

Recommended Posts

Hi,

 

I'm trying to compile the Odroid-XU4 kernel using a make -C KERNEL_SOURCES O=SOMEWHERE_ELSE/mybuild.

This command will failed when it reaches these drivers in drivers/net/wireless: rtl8188eu, rtl8189es, rtl8189fs, rtl8192eu, rtl8723ds, rtl8723du, rtl8811cu, rtl8812au, rtl8822bs, rtl88x2bu, rtl88x2cs.

To be able to compile the Kernel outside of the source tree I had to modify this list of files below. This is an output of my scipt wich is searching an replacing and replacing "-I$(src)" with "-I$(souce)/$(src)"

 

Fixing compilation for driver rtl8188eu ..
  Makefile
  phydm.mk
  sd4_phydm_2_kernel.mk
  ap_makefile.mk
Fixing compilation for driver rtl8189es ..
  Makefile
Fixing compilation for driver rtl8189fs ..
  Makefile
Fixing compilation for driver rtl8192eu ..
  Makefile
  phydm.mk
  sd4_phydm_2_kernel.mk
  ap_makefile.mk
Fixing compilation for driver rtl8723ds ..
  Makefile
Fixing compilation for driver rtl8723du ..
  Makefile
  phydm.mk
  sd4_phydm_2_kernel.mk
  ap_makefile.mk
Fixing compilation for driver rtl8811cu ..
  Makefile
  phydm.mk
  ap_makefile.mk
  rtl8821c.mk
Fixing compilation for driver rtl8812au ..
  Makefile
  phydm.mk
  sd4_phydm_2_kernel.mk
  ap_makefile.mk
Fixing compilation for driver rtl8822bs ..
  Makefile
  phydm.mk
  rtl8822b.mk
Fixing compilation for driver rtl88x2bu ..
  Makefile
  phydm.mk
  sd4_phydm_2_kernel.mk
  ap_makefile.mk
  halmac.mk
  rtl8822b.mk
Fixing compilation for driver rtl88x2cs ..
  Makefile
  phydm.mk
  sd4_phydm_2_kernel.mk
  ap_makefile.mk
  halmac.mk
  rtl8822c.mk

 

The script I used to fix this issue is this:

 

    for i in rtl8188eu rtl8189es rtl8189fs rtl8192eu rtl8723ds rtl8723du rtl8811cu rtl8812au rtl8822bs rtl88x2bu rtl88x2cs; do
        if [[ -d "${SOURCE_DIR}/drivers/net/wireless/$i" ]]; then
            echo "Fixing compilation for driver $i .."
            if [[ -f "${SOURCE_DIR}/drivers/net/wireless/$i/Makefile" ]]; then
                echo "  Makefile"
                sed -i -e "s/-I\$(src)/-I \$(srctree)\/\$(src)/g" "${SOURCE_DIR}/drivers/net/wireless/$i/Makefile"
            fi

            ### Also there are multiple .mk files with the same issue.
            for j in `find "${SOURCE_DIR}/drivers/net/wireless/$i/" -name *.mk -type f`; do
                echo "  $(basename $j)"
                sed -i "s/-I\$(src)/-I \$(srctree)\/\$(src)/g" "${j}"
            done
        fi
    done

 

There ${SOURCE_DIR} is obviously the Kernel sources from ArmBian.

 

Hope you can fix this issue in the next release of the kernel.

Link to comment
Share on other sites

8 hours ago, EasyNet said:

Hope you can fix this issue in the next release of the kernel.

 

I am grateful you have found a fix but sadly maintainers are unable to integrate most of the fixes that are found :( 

 

We are trying to improve the situation this way:

Applicants: 0


We are freezing code for next release today:

https://forum.armbian.com/topic/19188-armbian-2202-pig-release-thread/#comment-135629

https://docs.armbian.com/Process_Release-Model/

 

Probably it should be added here:
https://github.com/armbian/build/blob/master/lib/compilation-prepare.sh

 

then https://github.com/armbian/build/pulls

Link to comment
Share on other sites

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines