From: Roy Marples Date: Wed, 30 Jul 2014 09:46:33 +0000 (+0000) Subject: Fix the import to work on Linux as well. X-Git-Tag: v6.4.3~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c9c7e301b255b6007d394cac21a5cdca4177d03;p=thirdparty%2Fdhcpcd.git Fix the import to work on Linux as well. --- diff --git a/Makefile b/Makefile index bd4b9550..7bdf879c 100644 --- a/Makefile +++ b/Makefile @@ -16,13 +16,9 @@ CFLAGS+= -std=${CSTD} SRCS+= ${DHCPCD_SRCS} -.PATH: ./crypt - -VPATH= . ./crypt - SRCS+= auth.c CPPFLAGS+= -I./crypt -CRYPT_SRCS= hmac_md5.c ${MD5_SRC} ${SHA256_SRC} +CRYPT_SRCS= crypt/hmac_md5.c ${MD5_SRC} ${SHA256_SRC} OBJS+= ${SRCS:.c=.o} ${COMPAT_SRCS:.c=.o} ${CRYPT_SRCS:.c=.o} @@ -159,13 +155,10 @@ import: ${SRCS} sort -u) /tmp/${DISTPREFIX}; \ if test -n "${CRYPT_SRCS}"; then \ ${INSTALL} -d /tmp/${DISTPREFIX}/crypt; \ - cp $$(echo ${CRYPT_SRCS} | tr ' ' '\n' | \ - sed -e 's:^:crypt/:g') \ - /tmp/${DISTPREFIX}/crypt; \ - cp $$(cd crypt && ${CC} ${CPPFLAGS} -MM ${CRYPT_SRCS} | \ + cp ${CRYPT_SRCS} /tmp/${DISTPREFIX}/crypt; \ + cp $$(${CC} ${CPPFLAGS} -MM ${CRYPT_SRCS} | \ sed -e 's/^.*c //g' -e 's/.*\.c$$//g' -e 's/\\//g' | \ - tr ' ' '\n' | sed -e '/config.h/d' \ - -e 's:^:crypt/:g' | \ + tr ' ' '\n' | sed -e '/\/\.\.\//d' | \ sort -u) /tmp/${DISTPREFIX}/crypt; \ fi; if test -n "${COMPAT_SRCS}"; then \ diff --git a/configure b/configure index 3c7fca93..9c322223 100755 --- a/configure +++ b/configure @@ -819,7 +819,7 @@ EOF rm -f _md5.c _md5 fi if [ "$MD5" = no ]; then - echo "MD5_SRC= md5.c" >>$CONFIG_MK + echo "MD5_SRC= crypt/md5.c" >>$CONFIG_MK else echo "MD5_SRC=" >>$CONFIG_MK echo "#define HAVE_MD5_H" >>$CONFIG_H @@ -909,7 +909,7 @@ EOF fi fi if [ "$SHA2" = no ]; then - echo "SHA256_SRC= sha256.c" >>$CONFIG_MK + echo "SHA256_SRC= crypt/sha256.c" >>$CONFIG_MK else echo "SHA256_SRC=" >>$CONFIG_MK echo "#define SHA2_H <$SHA2_H>" >>$CONFIG_H diff --git a/crypt/sha256.c b/crypt/sha256.c old mode 100755 new mode 100644 diff --git a/crypt/sha256.h b/crypt/sha256.h old mode 100755 new mode 100644