- CC="$(TARGET_CC)" \
- CFLAGS="$(TARGET_CFLAGS) -I. -Isrc -Dlinux -I../../src -DNODEBUG" \
- all
-
-$(PKG_IPK): $(PKG_BUILD_DIR)/$(PKG_NAME)
- $(SCRIPT_DIR)/make-ipkg-dir.sh $(PKG_IPK_DIR) $(PKG_NAME).control $(PKG_VERSION)-$(PKG_RELEASE) $(ARCH)
- mkdir -p $(PKG_IPK_DIR)/usr/sbin
- mkdir -p $(PKG_IPK_DIR)/usr/lib
- cp $(PKG_BUILD_DIR)/$(PKG_NAME) $(PKG_IPK_DIR)/usr/sbin/
- cp $(PKG_BUILD_DIR)/lib/dyn_gw/olsrd_dyn_gw.so.0.3 $(PKG_IPK_DIR)/usr/lib/
- cp $(PKG_BUILD_DIR)/lib/nameservice/olsrd_nameservice.so.0.2 $(PKG_IPK_DIR)/usr/lib/
- cp $(PKG_BUILD_DIR)/lib/httpinfo/olsrd_httpinfo.so.0.1 $(PKG_IPK_DIR)/usr/lib/
- cp $(PKG_BUILD_DIR)/lib/secure/olsrd_secure.so.0.5 $(PKG_IPK_DIR)/usr/lib/
- $(STRIP) $(PKG_IPK_DIR)/usr/sbin/*
- $(STRIP) $(PKG_IPK_DIR)/usr/lib/*
- mkdir -p $(PACKAGE_DIR)
- $(IPKG_BUILD) $(PKG_IPK_DIR) $(PACKAGE_DIR)
-
-$(IPKG_STATE_DIR)/info/$(PKG_NAME).list: $(PKG_IPK)
- $(IPKG) install $(PKG_IPK)
-
-source: $(DL_DIR)/$(PKG_SOURCE)
-prepare: $(PKG_BUILD_DIR)/.unpacked
-compile: $(PKG_IPK)
-install: $(IPKG_STATE_DIR)/info/$(PKG_NAME).list
-
-clean:
- rm -rf $(PKG_BUILD_DIR)
- rm -f $(PKG_IPK)
+ install install_libs
+ touch $(PKG_BUILD_DIR)/.built
+
+$(IPKG_OLSRD):
+ install -d -m0755 $(IDIR_OLSRD)/etc
+ cp -fpR $(PKG_INSTALL_DIR)/etc/olsrd.conf $(IDIR_OLSRD)/etc/
+ install -d -m0755 $(IDIR_OLSRD)/usr/sbin
+ cp -fpR $(PKG_INSTALL_DIR)/usr/sbin/olsrd $(IDIR_OLSRD)/usr/sbin/
+ install -d -m0755 $(IDIR_OLSRD)/etc/init.d
+ cp -fpR ./files/olsrd.init $(IDIR_OLSRD)/etc/init.d/olsrd
+ $(RSTRIP) $(IDIR_OLSRD)
+ $(IPKG_BUILD) $(IDIR_OLSRD) $(PACKAGE_DIR)
+
+$(IPKG_OLSRD_MOD_SECURE): $(IDIR_OLSRD_MOD_SECURE)/etc/olsrd.d/olsrd_secure_key
+
+$(IDIR_OLSRD_MOD_SECURE)/etc/olsrd.d/olsrd_secure_key:
+ install -d -m0755 $(IDIR_OLSRD_MOD_SECURE)/etc/olsrd.d
+ cp -fpR ./files/olsrd_secure_key $(IDIR_OLSRD_MOD_SECURE)/etc/olsrd.d/