Skip to content

Commit 3dc0521

Browse files
rockdrillaaparcar
authored andcommitted
dropbear: simplify rebuild on config changes
It's hard or even impossible to track affected sources so it's safe to remove all built objects (if any). Signed-off-by: Konstantin Demin <rockdrilla@gmail.com>
1 parent d8ff2d8 commit 3dc0521

1 file changed

Lines changed: 2 additions & 9 deletions

File tree

  • package/network/services/dropbear

package/network/services/dropbear/Makefile

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -233,22 +233,15 @@ define Build/Configure/dropbear_headers
233233
))
234234
endef
235235

236-
define Build/Configure/dropbear_objects
237-
grep -ERZl -e '($(subst $(space),|,$(strip $(sort $(patsubst !!%,%,$(foreach s,$(DB_OPT_COMMON) $(DB_OPT_CONFIG),$(word 1,$(subst $(comma),$(space),$(s)))))))))' \
238-
$(PKG_BUILD_DIR)/ | sed -zE 's/^(.+)\.[^.]+$$$$/\1.o/' | sort -uV | xargs -0 -r rm -fv || :
239-
endef
240-
241236
define Build/Configure
242237
rm -f $(PKG_BUILD_DIR)/localoptions.h
243238
$(Build/Configure/Default)
244239

245240
: > $(PKG_BUILD_DIR)/localoptions.h
246241
$(Build/Configure/dropbear_headers)
247242

248-
# Enforce rebuild of files depending on configured options
249-
$(Build/Configure/dropbear_objects)
250-
251-
# Rebuild them on config change
243+
# Enforce rebuild
244+
rm -rf $(PKG_BUILD_DIR)/obj
252245
+$(MAKE) -C $(PKG_BUILD_DIR)/libtomcrypt clean
253246
+$(MAKE) -C $(PKG_BUILD_DIR)/libtommath clean
254247
endef

0 commit comments

Comments
 (0)