@ -9,6 +9,14 @@
ROOT_DIR = .
ROOT_DIR = .
i n c l u d e $( ROOT_DIR ) / M a k e f i l e . c o n f i g
i n c l u d e $( ROOT_DIR ) / M a k e f i l e . c o n f i g
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @libdir@
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
TARGETS_TO_TEST =
TARGETS_TO_TEST =
i f e q ( @ B U I L D _ C _ A N A L Y Z E R S @ , y e s )
i f e q ( @ B U I L D _ C _ A N A L Y Z E R S @ , y e s )
TARGETS_TO_TEST += c cpp
TARGETS_TO_TEST += c cpp
@ -135,6 +143,100 @@ test: ocaml_unit_test buck_test inferTraceBugs_test
test_xml : buck_test_xml
test_xml : buck_test_xml
uninstall :
$( REMOVE_DIR) $( DESTDIR) $( libdir) /infer/
$( REMOVE) $( DESTDIR) $( bindir) /inferTraceBugs
$( REMOVE) $( DESTDIR) $( bindir) /infer
install : $( INFER_ANALYZERS ) inferTraceBugs
# create directory structure
test -d $( DESTDIR) $( bindir) || \
$( MKDIR_P) $( DESTDIR) $( bindir)
test -d $( DESTDIR) $( libdir) /infer/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/
i f e q ( @ B U I L D _ C _ A N A L Y Z E R S @ , y e s )
test -d $( DESTDIR) $( libdir) /infer/facebook-clang-plugins/libtooling/build/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/facebook-clang-plugins/libtooling/build/
@for i in $$ ( find facebook-clang-plugins/clang/ -not -wholename 'src/*' -type d) ; do \
test -d $( DESTDIR) $( libdir) /infer/$$ i || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/$$ i; \
done
test -d $( DESTDIR) $( libdir) /infer/infer/lib/clang_wrappers/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/clang_wrappers/
e n d i f
i f e q ( @ B U I L D _ J A V A _ A N A L Y Z E R S @ , y e s )
test -d $( DESTDIR) $( libdir) /infer/infer/lib/java/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/java/
e n d i f
i f n e q ( @ X C O D E _ S E L E C T @ , n o )
test -d $( DESTDIR) $( libdir) /infer/infer/lib/xcode_wrappers/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/xcode_wrappers/
e n d i f
test -d $( DESTDIR) $( libdir) /infer/infer/annotations/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/annotations/
test -d $( DESTDIR) $( libdir) /infer/infer/lib/wrappers/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/wrappers/
test -d $( DESTDIR) $( libdir) /infer/infer/lib/specs/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/specs/
test -d $( DESTDIR) $( libdir) /infer/infer/lib/python/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/python/
test -d $( DESTDIR) $( libdir) /infer/infer/lib/python/inferlib/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/python/inferlib/
test -d $( DESTDIR) $( libdir) /infer/infer/lib/python/inferlib/capture/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/lib/python/inferlib/capture/
test -d $( DESTDIR) $( libdir) /infer/infer/bin/ || \
$( MKDIR_P) $( DESTDIR) $( libdir) /infer/infer/bin/
# copy files
i f e q ( @ B U I L D _ C _ A N A L Y Z E R S @ , y e s )
$( INSTALL_DATA) -C facebook-clang-plugins/libtooling/build/FacebookClangPlugin.dylib \
$( DESTDIR) $( libdir) /infer/facebook-clang-plugins/libtooling/build/FacebookClangPlugin.dylib
@for i in $$ ( find facebook-clang-plugins/clang/ -not -wholename 'src/*' -not -name setup.sh -not -name installed.version -not -type d) ; do \
$( INSTALL_PROGRAM) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
@for i in $$ ( find infer/lib/clang_wrappers/*) ; do \
$( INSTALL_PROGRAM) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
@for i in $$ ( find infer/lib/specs/*) ; do \
$( INSTALL_DATA) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
$( INSTALL_PROGRAM) -C $( INFERCLANG_BIN) $( DESTDIR) $( libdir) /infer/infer/bin/
e n d i f
i f n e q ( @ X C O D E _ S E L E C T @ , n o )
@for i in $$ ( find infer/lib/xcode_wrappers/*) ; do \
$( INSTALL_PROGRAM) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
e n d i f
i f e q ( @ B U I L D _ J A V A _ A N A L Y Z E R S @ , y e s )
$( INSTALL_DATA) -C infer/annotations/annotations.jar \
$( DESTDIR) $( libdir) /infer/infer/annotations/annotations.jar
@for i in infer/lib/java/*.jar; do \
$( INSTALL_DATA) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
$( INSTALL_PROGRAM) -C $( INFERJAVA_BIN) $( DESTDIR) $( libdir) /infer/infer/bin/
e n d i f
@for i in $$ ( find infer/lib/wrappers/*) ; do \
$( INSTALL_PROGRAM) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
@for i in $$ ( find infer/lib/python/inferlib/* -type f) ; do \
$( INSTALL_DATA) -C $$ i $( DESTDIR) $( libdir) /infer/$$ i; \
done
$( INSTALL_PROGRAM) -C infer/lib/python/infer \
$( DESTDIR) $( libdir) /infer/infer/lib/python/infer
$( INSTALL_PROGRAM) -C infer/lib/python/inferTraceBugs \
$( DESTDIR) $( libdir) /infer/infer/lib/python/inferTraceBugs
$( INSTALL_PROGRAM) -C $( INFERANALYZE_BIN) $( DESTDIR) $( libdir) /infer/infer/bin/
$( INSTALL_PROGRAM) -C $( INFERPRINT_BIN) $( DESTDIR) $( libdir) /infer/infer/bin/
( cd $( DESTDIR) $( libdir) /infer/infer/bin/ && \
$( REMOVE) infer && \
$( LN_S) $( DESTDIR) $( libdir) /infer/infer/lib/python/infer infer)
( cd $( DESTDIR) $( bindir) / && \
$( REMOVE) infer && \
$( LN_S) $( DESTDIR) $( libdir) /infer/infer/lib/python/infer infer)
( cd $( DESTDIR) $( bindir) / && \
$( REMOVE) inferTraceBugs && \
$( LN_S) $( DESTDIR) $( libdir) /infer/infer/lib/python/inferTraceBugs inferTraceBugs)
clean :
clean :
@rm -fv test.xml
@rm -fv test.xml
i f e q ( @ B U I L D _ C _ A N A L Y Z E R S @ , y e s )
i f e q ( @ B U I L D _ C _ A N A L Y Z E R S @ , y e s )
@ -146,3 +248,4 @@ endif
.PHONY : all buck_test buck_test_xml clean clang
.PHONY : all buck_test buck_test_xml clean clang
.PHONY : clang_plugin clang_setup inferTraceBugs inferTraceBugs_test java
.PHONY : clang_plugin clang_setup inferTraceBugs inferTraceBugs_test java
.PHONY : ocaml_unit_test test test_xml test_build unit
.PHONY : ocaml_unit_test test test_xml test_build unit
.PHONY : install uninstall