| 
									
										
										
										
											2012-05-15 08:47:19 +08:00
										 |  |  | # Install headers
 | 
					
						
							|  |  |  | file(GLOB discrete_headers "*.h")
 | 
					
						
							|  |  |  | install(FILES ${discrete_headers} DESTINATION include/gtsam_unstable/discrete)
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | # Components to link tests in this subfolder against
 | 
					
						
							|  |  |  | set(discrete_local_libs  | 
					
						
							|  |  |  |    discrete_unstable
 | 
					
						
							|  |  |  |    discrete
 | 
					
						
							|  |  |  |    inference
 | 
					
						
							|  |  |  |    base
 | 
					
						
							|  |  |  |    ccolamd
 | 
					
						
							|  |  |  | )
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | set (discrete_full_libs | 
					
						
							| 
									
										
										
										
											2013-03-14 02:17:39 +08:00
										 |  |  |     ${gtsam-default}
 | 
					
						
							|  |  |  |     ${gtsam_unstable-default})
 | 
					
						
							| 
									
										
										
										
											2012-05-15 08:47:19 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | # Exclude tests that don't work
 | 
					
						
							| 
									
										
										
										
											2012-05-25 23:10:13 +08:00
										 |  |  | #set (discrete_excluded_tests 
 | 
					
						
							|  |  |  | #"${CMAKE_CURRENT_SOURCE_DIR}/tests/testScheduler.cpp"
 | 
					
						
							|  |  |  | #)
 | 
					
						
							| 
									
										
										
										
											2012-05-22 03:44:24 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2012-05-15 08:47:19 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | # Add all tests
 | 
					
						
							|  |  |  | gtsam_add_subdir_tests(discrete_unstable "${discrete_local_libs}" "${discrete_full_libs}" "${discrete_excluded_tests}") 
 | 
					
						
							| 
									
										
										
										
											2012-05-26 00:12:55 +08:00
										 |  |  | add_dependencies(check.unstable check.discrete_unstable)
 | 
					
						
							| 
									
										
										
										
											2012-05-15 08:47:19 +08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2012-05-22 04:21:09 +08:00
										 |  |  | # List examples to build - comment out here to exclude from compilation
 | 
					
						
							|  |  |  | set(discrete_unstable_examples | 
					
						
							| 
									
										
										
										
											2012-06-06 20:51:44 +08:00
										 |  |  | schedulingExample
 | 
					
						
							|  |  |  | schedulingQuals12
 | 
					
						
							| 
									
										
										
										
											2012-05-22 04:21:09 +08:00
										 |  |  | )
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2012-05-21 01:38:46 +08:00
										 |  |  | if (GTSAM_BUILD_EXAMPLES)
 | 
					
						
							| 
									
										
										
										
											2012-05-22 04:21:09 +08:00
										 |  |  |     foreach(example ${discrete_unstable_examples})
 | 
					
						
							| 
									
										
										
										
											2012-05-21 01:38:46 +08:00
										 |  |  |     	add_executable(${example} "examples/${example}.cpp")
 | 
					
						
							|  |  |  |     	
 | 
					
						
							|  |  |  |     	# Disable building during make all/install
 | 
					
						
							|  |  |  |         if (GTSAM_ENABLE_INSTALL_EXAMPLE_FIX)
 | 
					
						
							|  |  |  |             set_target_properties(${example} PROPERTIES EXCLUDE_FROM_ALL ON)
 | 
					
						
							|  |  |  |         endif()
 | 
					
						
							|  |  |  |     	
 | 
					
						
							| 
									
										
										
										
											2012-06-07 12:53:52 +08:00
										 |  |  | 		if(NOT MSVC)
 | 
					
						
							|  |  |  | 			add_dependencies(examples ${example})
 | 
					
						
							|  |  |  | 			add_custom_target(${example}.run ${EXECUTABLE_OUTPUT_PATH}${example} ${ARGN})
 | 
					
						
							|  |  |  | 		endif()
 | 
					
						
							| 
									
										
										
										
											2012-05-21 01:38:46 +08:00
										 |  |  |     	
 | 
					
						
							| 
									
										
										
										
											2013-03-14 02:17:39 +08:00
										 |  |  |     	target_link_libraries(${example} ${gtsam-default} ${gtsam_unstable-default})
 | 
					
						
							| 
									
										
										
										
											2012-05-21 01:38:46 +08:00
										 |  |  |     endforeach(example)
 | 
					
						
							|  |  |  | endif (GTSAM_BUILD_EXAMPLES)
 |