You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
36 lines
1.0 KiB
36 lines
1.0 KiB
//===- SearchDirCmd.cpp ---------------------------------------------------===//
|
|
//
|
|
// The MCLinker Project
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
#include "mcld/Script/SearchDirCmd.h"
|
|
|
|
#include "mcld/Support/raw_ostream.h"
|
|
#include "mcld/LinkerScript.h"
|
|
#include "mcld/Module.h"
|
|
|
|
namespace mcld {
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
// SearchDirCmd
|
|
//===----------------------------------------------------------------------===//
|
|
SearchDirCmd::SearchDirCmd(const std::string& pPath)
|
|
: ScriptCommand(ScriptCommand::SEARCH_DIR), m_Path(pPath) {
|
|
}
|
|
|
|
SearchDirCmd::~SearchDirCmd() {
|
|
}
|
|
|
|
void SearchDirCmd::dump() const {
|
|
mcld::outs() << "SEARCH_DIR ( " << m_Path << " )\n";
|
|
}
|
|
|
|
void SearchDirCmd::activate(Module& pModule) {
|
|
pModule.getScript().directories().insert(m_Path);
|
|
}
|
|
|
|
} // namespace mcld
|