blob: f45f1b42ba982429daed184ca790db07dd06989a [file] [log] [blame]
Emil Velikovbbae65e2014-03-02 20:59:39 +00001# Provide compatibility with scripts for the old Mesa build system for
2# a while by putting a link to the driver into /lib of the build tree.
3
Emil Velikov4d8267e2014-03-12 18:13:02 +00004if BUILD_SHARED
Emil Velikov22c13352014-03-09 11:50:44 +00005if HAVE_COMPAT_SYMLINKS
Emil Velikovbbae65e2014-03-02 20:59:39 +00006all-local : .libs/install-gallium-links
7
Emil Velikov291d7022014-06-21 12:31:47 +01008.libs/install-gallium-links : $(dri_LTLIBRARIES) $(egl_LTLIBRARIES) $(lib_LTLIBRARIES)
Emil Velikovbbae65e2014-03-02 20:59:39 +00009 $(AM_V_GEN)$(MKDIR_P) $(top_builddir)/$(LIB_DIR); \
10 link_dir=$(top_builddir)/$(LIB_DIR)/gallium; \
11 if test x$(egl_LTLIBRARIES) != x; then \
12 link_dir=$(top_builddir)/$(LIB_DIR)/egl; \
13 fi; \
14 $(MKDIR_P) $$link_dir; \
Emil Velikov55f9bbd2014-04-07 15:24:46 +010015 file_list=$(dri_LTLIBRARIES:%.la=.libs/%.so); \
Emil Velikovbba9c282014-03-08 19:48:04 +000016 file_list+=$(egl_LTLIBRARIES:%.la=.libs/%.$(LIB_EXT)*); \
17 file_list+=$(lib_LTLIBRARIES:%.la=.libs/%.$(LIB_EXT)*); \
Emil Velikovbbae65e2014-03-02 20:59:39 +000018 for f in $$file_list; do \
19 if test -h .libs/$$f; then \
20 cp -d $$f $$link_dir; \
21 else \
22 ln -f $$f $$link_dir; \
23 fi; \
24 done && touch $@
Emil Velikov22c13352014-03-09 11:50:44 +000025endif
Emil Velikov4d8267e2014-03-12 18:13:02 +000026endif