Gibt es einen Trick den man anwenden muss um Boost zu benutzen?
Ich habe mal zum Test in der zapit.cpp das hier rausgenommen und mit einer Boost-Funktion ersetzt.
Code: Alles auswählen
void cpy(char * from, char * to)
{
char cmd[256] = "cp -f ";
strcat(cmd, from);
strcat(cmd, " ");
strcat(cmd, to);
system(cmd);
}
cpy(BOUQUETS_TMP, BOUQUETS_XML);
wird
boost::filesystem::copy_file(BOUQUETS_TMP, BOUQUETS_XML);
Und natürlich auch:
#include <boost/filesystem/operations.hpp>
Compilen funktioniert damit aber nicht.
zapit.o: In function `mergeBouquets()':
zapit.cpp:(.text+0x1360): undefined reference to `boost::filesystem::path::path(char const*)'
zapit.cpp:(.text+0x136c): undefined reference to `boost::filesystem::path::path(char const*)'
zapit.cpp:(.text+0x1378): undefined reference to `boost::filesystem::copy_file(boost::filesystem::path const&, boost::filesystem::path const&)'
Im SectionsD gehts ja auch nicht anders.
Include, Funktion benutzen, fertig...
Jemand eine Idee?
Gruß