OpenWrt Forum Archive

Topic: nfs-utils without needing OpenLDAP

The content of this topic has been archived on 29 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hi guys,

I'm trying to compile nfs-utils without the need for other packages, because i've no much room left on my asus wl500-gd for the OpenLDAP package and openssl...
so i tried to compile the nfs-utils by myself. I've read the manual on http://downloads.openwrt.org/docs/build … ation.html and folowed the instructions. But now, there is a problem while striping the binaries: "strip: Unable to recognise the format of the input file"

How can I prevent this package of being stripped?

Thanks

change the makefile of the package and remove the $(RSTRIP) call...

Hi wbx,
thank you for your reply, but it doesn't help.

Here is my Makefile for reviewing:

---------------------------------------------------------------------------------------------------------------------------------
include $(TOPDIR)/rules.mk

PKG_NAME:=nfs-utils
PKG_VERSION:=1.0.7
PKG_RELEASE:=1

PKG_SOURCE_URL:=http://www.us.kernel.org/pub/linux/utils/nfs
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_CAT:=zcat

PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install

include $(TOPDIR)/package/rules.mk

$(eval $(call PKG_template,NFS_UTILS,nfs-utils,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))

$(PKG_BUILD_DIR)/.configured:
    (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
        $(TARGET_CONFIGURE_OPTS) \
        CFLAGS="$(TARGET_CFLAGS)" \
        CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
        LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
        ./configure \
          --prefix=/ \
          --target=$(GNU_TARGET_NAME) \
          --host=$(GNU_TARGET_NAME) \
          --build=$(GNU_HOST_NAME) \
          --program-prefix="" \
          --program-suffix="" \
          --enable-nfsv3 \
          --disable-gss \
          --disable-nfsv4 \
          --with-statduser=root \
          --with-bar="$(STAGING_DIR)/usr" \
          $(DISABLE_LARGEFILE) \
          $(DISABLE_NLS) \
    );
    touch $@

$(PKG_BUILD_DIR)/.built:
    rm -rf $(PKG_INSTALL_DIR)
    mkdir -p $(PKG_INSTALL_DIR)
    $(MAKE) -C $(PKG_BUILD_DIR) \
        $(TARGET_CONFIGURE_OPTS) \
        install_prefix="$(PKG_INSTALL_DIR)" \
        all install
    touch $@

$(IPKG_NFS_UTILS):
    install -d -m0755 $(IDIR_NFS_UTILS)/usr/sbin
    cp -fpR $(PKG_INSTALL_DIR)/usr/sbin/nfs-utils $(IDIR_NFS_UTILS)/usr/sbin
    $(RSTRIP) $(IDIR_NFS_UTILS)
    $(IPKG_BUILD) $(IDIR_NFS_UTILS) $(PACKAGE_DIR)

-------------------------------------------------------------------------------------------------------------------------
the strip error looks like folowing:

-------------------------------------------------------------------------------------------------------------------------
...
mkdir -p /home/pfeifer/openwrt/src/openwrt/build_mipsel/nfs-utils-1.0.7/ipkg-install//sbin
install -m 755 -s exportfs /home/pfeifer/openwrt/src/openwrt/build_mipsel/nfs-utils-1.0.7/ipkg-install//sbin/exportfs
strip: Unable to recognise the format of the input file /home/pfeifer/openwrt/src/openwrt/build_mipsel/nfs-utils-1.0.7/ipkg-install//sbin/exportfs
install: strip fehlgeschlagen
make[5]: *** [install] Fehler 1

-------------------------------------------------------------------------------------------------------------------------------------------------

Please, can anyone help me?

Thanks

mkdir -p /home/pfeifer/openwrt/src/openwrt/build_mipsel/nfs-utils-1.0.7/ipkg-install//sbin
install -m 755 -s exportfs /home/pfeifer/openwrt/src/openwrt/build_mipsel/nfs-utils-1.0.7/ipkg-install//sbin/exportfs
strip: Unable to recognise the format of the input file

The "-s" option passed to the "install" command would strip the binary. You should remove it in original makefiles.

The discussion might have continued from here.