##### dtiDroid/src CMakeLists ########################################
##### $Id: CMakeLists.txt 296 2009-09-23 00:31:23Z rouchdyy@UPHS.PENNHEALTH.PRV $ ##########
#######################################################################

#Build the libraries...
ADD_LIBRARY(mvcd mvcd.c )
ADD_LIBRARY(matrixSHEN matrixSHEN.c )
ADD_LIBRARY(adaptivebrain adaptivebrain.c )

#build the executables...
ADD_EXECUTABLE(resample resample.c)
TARGET_LINK_LIBRARIES(resample mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(cortexgmlabelcorrection cortexgmlabelcorrection.c)
TARGET_LINK_LIBRARIES(cortexgmlabelcorrection mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(nucleus nucleus.c)
TARGET_LINK_LIBRARIES(nucleus mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(comparevectorfields comparevectorfields.c)
TARGET_LINK_LIBRARIES(comparevectorfields mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(cropslices cropslices.c)
TARGET_LINK_LIBRARIES(cropslices mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(performdeformationusingvectorfield performdeformationusingvectorfield.c)
TARGET_LINK_LIBRARIES(performdeformationusingvectorfield mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(splitfile splitfile.c)
TARGET_LINK_LIBRARIES(splitfile mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(transform3dvectorfield transform3dvectorfield.c)
TARGET_LINK_LIBRARIES(transform3dvectorfield mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(transform3dimg transform3dimg.c)
TARGET_LINK_LIBRARIES(transform3dimg mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(fslmat2mymat fslmat2mymat.c)
TARGET_LINK_LIBRARIES(fslmat2mymat mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(rigidtransform rigidtransform.c)
TARGET_LINK_LIBRARIES(rigidtransform mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(ravens ravens.c)
TARGET_LINK_LIBRARIES(ravens mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(nucleus3 nucleus3.c)
TARGET_LINK_LIBRARIES(nucleus3 mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(changelinevalueinimg changelinevalueinimg.c)
TARGET_LINK_LIBRARIES(changelinevalueinimg mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(extractventricle extractventricle.c)
TARGET_LINK_LIBRARIES(extractventricle mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(makeavwheader makeavwheader.c)
TARGET_LINK_LIBRARIES(makeavwheader mvcd matrixSHEN adaptivebrain)
	
ADD_EXECUTABLE(printavwheader printavwheader.c)
TARGET_LINK_LIBRARIES(printavwheader mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(3dregiongrowing 3dregiongrowing.c)
TARGET_LINK_LIBRARIES(3dregiongrowing mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(maskout3dimg maskout3dimg.c)
TARGET_LINK_LIBRARIES(maskout3dimg mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(stack2edgemap stack2edgemap.c)
TARGET_LINK_LIBRARIES(stack2edgemap mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(closingholesinbinaryimg closingholesinbinaryimg.c)
TARGET_LINK_LIBRARIES(closingholesinbinaryimg mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(imageinfo imageinfo.c)
TARGET_LINK_LIBRARIES(imageinfo mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(usimageinfo usimageinfo.c)
TARGET_LINK_LIBRARIES(usimageinfo mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(twoimgop twoimgop.c)
TARGET_LINK_LIBRARIES(twoimgop mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(ustwoimgop ustwoimgop.c)
TARGET_LINK_LIBRARIES(ustwoimgop mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(ftwoimgop ftwoimgop.c)
TARGET_LINK_LIBRARIES(ftwoimgop mvcd matrixSHEN adaptivebrain)

ADD_EXECUTABLE(avimgvol avimgvol.c)
TARGET_LINK_LIBRARIES(avimgvol mvcd matrixSHEN adaptivebrain)

INSTALL(TARGETS
	resample
	cortexgmlabelcorrection
	nucleus
	comparevectorfields
	cropslices
	performdeformationusingvectorfield
	splitfile
	transform3dvectorfield
	transform3dimg
	fslmat2mymat
	rigidtransform
	ravens
	nucleus3
	changelinevalueinimg
	extractventricle
	makeavwheader
	printavwheader
	3dregiongrowing
	maskout3dimg
	stack2edgemap
	closingholesinbinaryimg
	imageinfo
	usimageinfo
	twoimgop
	ustwoimgop
	ftwoimgop
	avimgvol	
	mvcd
	matrixSHEN
	adaptivebrain  

  RUNTIME DESTINATION bin
  LIBRARY DESTINATION lib
  ARCHIVE DESTINATION lib
)
