X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fpkgconfigaction.cpp;h=c390fbd0e0a47dd45ee1e72995513411914e4866;hb=654de39b62a9a58fd8e1b5a557361d628345788b;hp=9c565f6ddcf5b1dc86588f8eb691b26beae19abe;hpb=57bdb055acb0453c75b22cb64f35cc0e817a2827;p=builder.git diff --git a/source/pkgconfigaction.cpp b/source/pkgconfigaction.cpp index 9c565f6..c390fbd 100644 --- a/source/pkgconfigaction.cpp +++ b/source/pkgconfigaction.cpp @@ -1,3 +1,10 @@ +/* $Id$ + +This file is part of builder +Copyright © 2006-2007 Mikko Rasa, Mikkosoft Productions +Distributed under the LGPL +*/ + #include #include #include @@ -10,29 +17,29 @@ using namespace std; PkgConfigAction::PkgConfigAction(Builder &b, const PkgConfig &p): Action(b) { - const Package &pkg=*p.get_package(); - - announce(pkg.get_name(), "PC", relative(p.get_name(), pkg.get_source()).str()); - + const SourcePackage &spkg=*static_cast(p.get_package()); + + announce(spkg.get_name(), "PC", relative(p.get_name(), spkg.get_source()).str()); + ofstream out(p.get_name().c_str()); if(out) { // Prefix is already included in the various paths //out<<"prefix="<get_package()->get_use_pkgconfig()) out<<' '<get_name(); out<<'\n'; - const BuildInfo &binfo=pkg.get_exported_binfo(); + const BuildInfo &binfo=spkg.get_exported_binfo(); out<<"Libs:"; for(StringList::const_iterator i=binfo.libpath.begin(); i!=binfo.libpath.end(); ++i) out<<" -L"<<*i;