mirror of
https://github.com/OpenMW/openmw.git
synced 2025-04-09 19:36:42 +00:00
Remove boost::filesystem from essimporter
This commit is contained in:
parent
7950ea1f54
commit
8a63bc0def
2 changed files with 2 additions and 4 deletions
|
@ -36,7 +36,6 @@ openmw_add_executable(openmw-essimporter
|
||||||
|
|
||||||
target_link_libraries(openmw-essimporter
|
target_link_libraries(openmw-essimporter
|
||||||
${Boost_PROGRAM_OPTIONS_LIBRARY}
|
${Boost_PROGRAM_OPTIONS_LIBRARY}
|
||||||
${Boost_FILESYSTEM_LIBRARY}
|
|
||||||
components
|
components
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,14 +1,13 @@
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
#include <filesystem>
|
||||||
|
|
||||||
#include <boost/program_options.hpp>
|
#include <boost/program_options.hpp>
|
||||||
#include <boost/filesystem.hpp>
|
|
||||||
|
|
||||||
#include <components/files/configurationmanager.hpp>
|
#include <components/files/configurationmanager.hpp>
|
||||||
|
|
||||||
#include "importer.hpp"
|
#include "importer.hpp"
|
||||||
|
|
||||||
namespace bpo = boost::program_options;
|
namespace bpo = boost::program_options;
|
||||||
namespace bfs = boost::filesystem;
|
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char** argv)
|
int main(int argc, char** argv)
|
||||||
|
@ -57,7 +56,7 @@ int main(int argc, char** argv)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
const std::string& ext = ".omwsave";
|
const std::string& ext = ".omwsave";
|
||||||
if (bfs::exists(bfs::path(outputFile))
|
if (std::filesystem::exists(std::filesystem::path(outputFile))
|
||||||
&& (outputFile.size() < ext.size() || outputFile.substr(outputFile.size()-ext.size()) != ext))
|
&& (outputFile.size() < ext.size() || outputFile.substr(outputFile.size()-ext.size()) != ext))
|
||||||
{
|
{
|
||||||
throw std::runtime_error("Output file already exists and does not end in .omwsave. Did you mean to use --compare?");
|
throw std::runtime_error("Output file already exists and does not end in .omwsave. Did you mean to use --compare?");
|
||||||
|
|
Loading…
Reference in a new issue