Browse Source

Fixes related to #253: FreeBSD build

merge-requests/365/head
eidheim 10 years ago
parent
commit
87108b26ba
  1. 2
      cmake_modules/FindLibClang.cmake
  2. 2
      src/directories.cc
  3. 2
      src/git.cc

2
cmake_modules/FindLibClang.cmake

@ -60,6 +60,7 @@ endforeach()
find_path(LIBCLANG_INCLUDE_DIR clang-c/Index.h
PATHS ${libclang_llvm_header_search_paths}
PATH_SUFFIXES LLVM/include #Windows package from http://llvm.org/releases/
llvm33/include llvm34/include llvm35/include llvm36/include llvm37/include llvm38/include llvm39/include # FreeBSD
DOC "The path to the directory that contains clang-c/Index.h")
# On Windows with MSVC, the import library uses the ".imp" file extension
@ -73,6 +74,7 @@ endif()
find_library(LIBCLANG_LIBRARY NAMES libclang.imp libclang clang
PATHS ${libclang_llvm_lib_search_paths}
PATH_SUFFIXES LLVM/lib #Windows package from http://llvm.org/releases/
llvm33/lib llvm34/lib llvm35/lib llvm36/lib llvm37/lib llvm38/lib llvm39/lib # FreeBSD
DOC "The file that corresponds to the libclang library.")
get_filename_component(LIBCLANG_LIBRARY_DIR ${LIBCLANG_LIBRARY} PATH)

2
src/directories.cc

@ -542,7 +542,7 @@ void Directories::add_or_update_path(const boost::filesystem::path &dir_path, co
if(path_it==directories.end()) {
auto g_file=Glib::wrap(g_file_new_for_path(dir_path.string().c_str())); //TODO: report missing constructor in giomm
#if GLIB_CHECK_VERSION(2, 44, 0)
#if GLIBMM_MAJOR_VERSION>2 || (GLIBMM_MAJOR_VERSION==2 && GLIBMM_MINOR_VERSION>=44)
auto monitor=g_file->monitor_directory(Gio::FileMonitorFlags::FILE_MONITOR_WATCH_MOVES);
#else
auto monitor=g_file->monitor_directory(Gio::FileMonitorFlags::FILE_MONITOR_SEND_MOVED);

2
src/git.cc

@ -104,7 +104,7 @@ Git::Repository::Repository(const boost::filesystem::path &path) {
auto git_path_str=boost::filesystem::canonical(get_path()).string();
auto git_directory=Glib::wrap(g_file_new_for_path(git_path_str.c_str())); //TODO: report missing constructor in giomm
#if GLIB_CHECK_VERSION(2, 44, 0)
#if GLIBMM_MAJOR_VERSION>2 || (GLIBMM_MAJOR_VERSION==2 && GLIBMM_MINOR_VERSION>=44)
monitor=git_directory->monitor_directory(Gio::FileMonitorFlags::FILE_MONITOR_WATCH_MOVES);
#else
monitor=git_directory->monitor_directory(Gio::FileMonitorFlags::FILE_MONITOR_SEND_MOVED);

Loading…
Cancel
Save