ruki 2 anos atrás
pai
commit
3acf676058
1 arquivos alterados com 7 adições e 4 exclusões
  1. 7 4
      configure

+ 7 - 4
configure

@@ -4185,12 +4185,13 @@ _gmake_add_install_target() {
         _get_target_soname "${target}"; local soname="${_ret}"
         if test_nz "${soname}" && test_nz "${version}"; then
             _get_target_extension "${target}"; local extension="${_ret}"
-            local targetfile_with_version="${installdir}/${filename}.${version}"
+            string_replace "${_install_libdir_default}" "\${prefix}" "${installdir}"; _install_libdir_default="${_ret}"
+            local targetfile_with_version="${_install_libdir_default}/${filename}.${version}"
             if test_eq "${extension}" ".dylib"; then
                 path_basename "${filename}"; local basename="${_ret}"
-                targetfile_with_version="${installdir}/${basename}.${version}${extension}"
+                targetfile_with_version="${_install_libdir_default}/${basename}.${version}${extension}"
             fi
-            local targetfile_with_soname="${installdir}/${soname}"
+            local targetfile_with_soname="${_install_libdir_default}/${soname}"
             path_filename "${targetfile_with_version}"; local targetfilename_with_version="${_ret}"
             if test_nq "${soname}" "${filename}" && test_nq "${soname}" "${targetfilename_with_version}"; then
                 install_for_soname=true
@@ -4205,9 +4206,11 @@ _gmake_add_install_target() {
         print "\t@mkdir -p ${_install_bindir_default}" >> "${xmake_sh_makefile}"
         print "\t@cp -p ${targetfile} ${_install_bindir_default}/${filename}" >> "${xmake_sh_makefile}"
     elif ${install_for_soname}; then
+        string_replace "${_install_libdir_default}" "\${prefix}" "${installdir}"; _install_libdir_default="${_ret}"
         print "\t@echo installing ${targetfile} to ${_install_libdir_default}" >> "${xmake_sh_makefile}"
+        print "\t@mkdir -p ${_install_libdir_default}" >> "${xmake_sh_makefile}"
         print "\t@cp -p ${targetfile} ${targetfile_with_version}" >> "${xmake_sh_makefile}"
-        print "\t@cd ${installdir} && ln -sf ${targetfilename_with_version} ${soname} && ln -sf ${soname} ${filename}" >> "${xmake_sh_makefile}"
+        print "\t@cd ${_install_libdir_default} && ln -sf ${targetfilename_with_version} ${soname} && ln -sf ${soname} ${filename}" >> "${xmake_sh_makefile}"
     elif test_eq "${targetkind}" "static" || test_eq "${targetkind}" "shared"; then
         string_replace "${_install_libdir_default}" "\${prefix}" "${installdir}"; _install_libdir_default="${_ret}"
         print "\t@echo installing ${targetfile} to ${_install_libdir_default}" >> "${xmake_sh_makefile}"