]> git.tdb.fi Git - builder.git/commitdiff
Fix shared library installation
authorMikko Rasa <tdb@tdb.fi>
Sun, 15 Jul 2012 17:14:01 +0000 (20:14 +0300)
committerMikko Rasa <tdb@tdb.fi>
Sun, 15 Jul 2012 17:31:10 +0000 (20:31 +0300)
source/installedfile.cpp

index 09cfed6db03a47165b3cb7c1834e2758244cc803..f4b8a939832efc0aa150c5bc10196bba9c3f42c2 100644 (file)
@@ -33,7 +33,12 @@ FS::Path InstalledFile::generate_target_path(const FS::Path &prefix, const FileT
        else
                mid = tgt.get_install_location();
 
-       return prefix/mid/FS::basename(tgt.get_path());
+       string fn = FS::basename(tgt.get_path());
+       if(const SharedLibrary *shlib = dynamic_cast<const SharedLibrary *>(&tgt))
+               if(!shlib->get_soname().empty())
+                       fn = shlib->get_soname();
+
+       return prefix/mid/fn;
 }
 
 Target *InstalledFile::get_real_target()