Commit 44a62b19 authored by Davis King's avatar Davis King

A bit of path cleanup

parent 8f3249a4
......@@ -14,7 +14,7 @@ include_directories(
# Additional dependencies
#include(../../dlib/cmake)
#set(additional_link_libraries dlib)
#set(additional_link_libraries dlib::dlib)
# Tell swig to put the output files (the shared library and .jar) into the local folder.
set(install_target_output_folder .)
......
......@@ -14,7 +14,7 @@
# ### can do that by setting additional_link_libraries. Here is an example of
# ### linking to dlib:
# include(../../dlib/dlib/cmake)
# set(additional_link_libraries dlib)
# set(additional_link_libraries dlib::dlib)
#
# ### Tell swig to put the output files into the parent folder of your CMakeLists.txt
# ### file when you run make install.
......@@ -40,7 +40,7 @@
################################################################################
################################################################################
cmake_minimum_required (VERSION 2.8.4)
cmake_minimum_required (VERSION 2.8.12)
# This block of code tries to figure out what the JAVA_HOME environment
# variable should be by looking at the folder that contains the java
......@@ -108,11 +108,14 @@ if (UNIX)
add_global_switch(-fPIC)
endif()
set(dlib_root_path ${CMAKE_CURRENT_LIST_DIR}/../../)
string(REGEX REPLACE "\\." "/" package_path ${java_package_name})
string(REGEX REPLACE "\\..*" "" package_root_name ${java_package_name})
set(CMAKE_SWIG_FLAGS -package ${java_package_name})
include_directories(${dlib_root_path})
set(CMAKE_SWIG_FLAGS -package ${java_package_name} -I${dlib_root_path})
set(CMAKE_SWIG_OUTDIR ${CMAKE_CURRENT_BINARY_DIR}/lib/java_src/${package_path})
set(output_library_name ${PROJECT_NAME})
......
......@@ -12,9 +12,9 @@
// function arguments. You do this by putting this pair of include statements in your
// swig_api.h file. Then after that you can use the java::array, java::array_view, and
// java::array_view_crit classes.
#include "java_array.h"
#include <dlib/java/java_array.h>
#ifdef SWIG
%include "java_array.h"
%include <dlib/java/java_array.h>
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment