diff --git a/net/htpdate/Makefile b/net/htpdate/Makefile index 53ca84767..8c1e9e3ef 100644 --- a/net/htpdate/Makefile +++ b/net/htpdate/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=htpdate -PKG_VERSION:=1.0.1 +PKG_VERSION:=1.0.4 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://www.clevervest.com/htp/archive/c/ -PKG_MD5SUM:=a0c2b7a3e89a9fedb1ae8cba17928ec3 +PKG_MD5SUM:=a13ec89839c33965794ebf53c4e690db include $(INCLUDE_DIR)/package.mk @@ -37,18 +37,17 @@ define Package/htpdate/conffiles /etc/default/htpdate endef -define Build/Compile +define Build/Compile $(MAKE) -C $(PKG_BUILD_DIR) \ $(TARGET_CONFIGURE_OPTS) \ CFLAGS="$(TARGET_CFLAGS)" endef - -define Package/htpdate/install +define Package/htpdate/install $(INSTALL_DIR) $(1)/usr/sbin $(INSTALL_BIN) $(PKG_BUILD_DIR)/htpdate $(1)/usr/sbin/ $(INSTALL_DIR) $(1)/etc/default/ - $(INSTALL_DATA) ./files/htpdate.default $(1)/etc/default/htpdate + $(INSTALL_CONF) ./files/htpdate.default $(1)/etc/default/htpdate $(INSTALL_DIR) $(1)/etc/init.d/ $(INSTALL_BIN) ./files/htpdate.init $(1)/etc/init.d/htpdate endef diff --git a/net/htpdate/patches/100-adjtimex.patch b/net/htpdate/patches/100-adjtimex.patch index 755188526..ec7c8a98e 100644 --- a/net/htpdate/patches/100-adjtimex.patch +++ b/net/htpdate/patches/100-adjtimex.patch @@ -1,6 +1,6 @@ --- a/htpdate.c +++ b/htpdate.c -@@ -349,7 +349,7 @@ +@@ -359,7 +359,7 @@ static int htpdate_adjtimex( double drif /* Read current kernel frequency */ tmx.modes = 0; @@ -9,12 +9,12 @@ /* Calculate new frequency */ freq = (long)(65536e6 * drift); -@@ -364,7 +364,7 @@ +@@ -377,7 +377,7 @@ static int htpdate_adjtimex( double drif + printlog( 1, "seteuid()" ); + exit(1); + } else { +- return( ntp_adjtime(&tmx) ); ++ return( adjtimex(&tmx) ); + } - /* Become root */ - seteuid(0); -- return( ntp_adjtime(&tmx) ); -+ return( adjtimex(&tmx) ); } - -