[Build Error] "Package registered twice" error when adding custom packages (exigo / luci-app-exigo)
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 28.5k
- Forks
- 13k
- PR merge metrics
- PR metrics pending
Description
Describe the bug
I am encountering a "Package registered twice" build error while compiling OpenWrt for my target device. I have added two custom packages (exigo and luci-app-exigo) and the build system seems to have cached a duplicate registration, even after attempting several cleanup commands.
Environment
Target Device: [Es: IPQ5018 / Xunison Exigo Hub D50-5G]
Host OS: [Es: Ubuntu 22.04 / Debian 12]
OpenWrt Source: [Es: Main branch / ImmortalWrt 23.05]
Steps to Reproduce
Created directory package/exigo and package/luci-app-exigo.
Added corresponding Makefile files to both directories.
Ran make defconfig and started compilation with make -j$(nproc).
The build fails with the error: Package registered twice.
What I've already tried
I have attempted to clear the build cache to resolve potential metadata conflicts, but the error persists:
rm -rf tmp/
make package/cleanup
make dirclean
make defconfig
Verified that PKG_NAME and define Package/... are unique and distinct in both Makefile files.
Additional Context
I have checked the OpenWrt forum and existing issues on GitHub, confirming this is likely a stale metadata issue, but standard cleanup procedures are not resolving the conflict in my build environment.
OpenWrt version
VERSION_NUMBER:=23.05.0
OpenWrt release
VERSION_CODE:=$(shell git describe --tags 2>/dev/null || echo "r0-unknown")
OpenWrt target/subtarget
grep "CONFIG_TARGET_BOARD" .config e grep "CONFIG_TARGET_SUBTARGET" .config
Device
xunison_exigo-hub-d50-5g
Image kind
Self-built image
Steps to reproduce
No response
Actual behaviour
No response
Expected behaviour
No response
Additional info
No response
Diffconfig
Terms
- I am reporting an issue for OpenWrt, not an unsupported fork.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Inspect the Makefiles under package/exigo and package/luci-app-exigo, then rerun the build after reviewing the full duplicate-registration error. Compare each PKG_NAME and define Package/... declaration and document which registration is duplicated; the issue lacks the actual error output and Makefile contents needed to confirm the cause.
Written by the indexing model from the issue text.
Assessment
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 42/100