The build system failed to compile some packages into the firmware

I use this .config to compile a couple disc utilities into the firmware. It built successfully, but after flashing the firmware, some packages (e.g., lsblk, resize2fs, losetup) were correctly preinstalled, but other packages (e.g., parted, sgdisk) were not.

CONFIG_TARGET_x86=y
CONFIG_TARGET_x86_64=y
CONFIG_TARGET_x86_64_DEVICE_generic=y
# CONFIG_FEED_custom is not set
# CONFIG_GRUB_IMAGES is not set
CONFIG_IMAGEOPT=y
CONFIG_PACKAGE_libmount=y
CONFIG_PACKAGE_libncurses=y
CONFIG_PACKAGE_libparted=y
CONFIG_PACKAGE_libpopt=y
CONFIG_PACKAGE_libreadline=y
CONFIG_PACKAGE_libstdcpp=y
CONFIG_PACKAGE_losetup=y
CONFIG_PACKAGE_lsblk=y
CONFIG_PACKAGE_parted=y
CONFIG_PACKAGE_resize2fs=y
CONFIG_PACKAGE_sgdisk=y
CONFIG_PACKAGE_terminfo=y

This config is generated from scripts/diffconfig.sh, and is expanded by first copying to <buildroot>/.config and then make defconfig. The OpenWrt version is 22.03.3.

I wonder what might be the reason that some packages get compiled in, but some do not?

Is there anything useful in the build logs?

Thanks for the quick reply.

Since the build was successful. There are no useful error messages I can paste.

But one thing I noticed is that, for not preinstalled packages like parted, there were only two entries containing the package name in the build logs:

2023-04-05T02:56:09.1712371Z Collecting package info: feeds/packages/utils/partede[M
2023-04-05T02:56:36.8490795Z Installing package 'parted' from packages

I believe that was from the feeds command:

scripts/feeds update -a
scripts/feeds install -a

But for preinstalled packages like losetup, it contained entries like

2023-04-05T04:11:04.5490207Z losetup (5.5 kb) (LOSETUP) [N/y/?] n
2023-04-05T04:13:51.8250195Z Installing losetup (2.37.4-1) to root...
2023-04-05T04:13:51.8304281Z Configuring losetup.
2023-04-05T04:14:25.4789957Z Generating index for package ./losetup_2.37.4-1_x86_64.ipk

After some more testing, I think it was because I didn't generate .config with the correct order. This was what I did:

  1. Copy over the short version of .config
  2. Run feeds update & install
  3. Run make defconfig

And somehow step 2 overwrote .config. I moved step 1 below step 2, it seems to be working.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.