1 # Created by: Yuri Victorovich <yuri@rawbw.com>
4 PORTNAME= inotify-tools # new fork https://github.com/ericcurtin/inotify-tools
8 MAINTAINER= yuri@FreeBSD.org
9 COMMENT= Command-line utilities to watch for file events
12 LICENSE_FILE= ${WRKSRC}/COPYING
14 LIB_DEPENDS= libinotify.so:devel/libinotify
16 USES= autoreconf gmake libtool localbase
19 CONFIGURE_ARGS= --disable-doxygen
21 INSTALL_TARGET= install-strip
23 OPTIONS_DEFINE= STATIC
27 @${REINPLACE_CMD} -e 's|stat64|stat|' \
28 ${WRKSRC}/src/common.c \
29 ${WRKSRC}/libinotifytools/src/inotifytools.c
32 @cd ${WRKSRC}/src && \
33 ${CC} -pthread ${LDFLAGS} -static -o inotifywait.static inotifywait.o common.o ../libinotifytools/src/.libs/libinotifytools.a ${LOCALBASE}/lib/libinotify.a && \
34 ${CC} -pthread ${LDFLAGS} -static -o inotifywatch.static inotifywatch.o common.o ../libinotifytools/src/.libs/libinotifytools.a ${LOCALBASE}/lib/libinotify.a
36 post-install-STATIC-on:
37 ${INSTALL_PROGRAM} ${WRKSRC}/src/inotifywait.static ${STAGEDIR}${PREFIX}/bin
38 ${INSTALL_PROGRAM} ${WRKSRC}/src/inotifywatch.static ${STAGEDIR}${PREFIX}/bin
40 do-test: # Some tests are known to fail: https://github.com/inotify-tools/inotify-tools/issues/108
42 @cd ${WRKSRC}/libinotifytools/src && ${GMAKE} test && ./test
43 @${ECHO} "integration test"
44 @cd ${WRKSRC}/t && ${GMAKE}
46 .include <bsd.port.mk>