X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/653824fd3a6edd3824babaa15f2416c11fcced19..6b0684975782916e6257c792879e1c0f3963411b:/examples/java/CMakeLists.txt diff --git a/examples/java/CMakeLists.txt b/examples/java/CMakeLists.txt index 0c8162e086..0e1967b218 100644 --- a/examples/java/CMakeLists.txt +++ b/examples/java/CMakeLists.txt @@ -1,34 +1,34 @@ -set(app_bittorrent_files Main Common Connection MessageTask Peer Tracker TrackerTask) -set(app_centralizedmutex_files Main Coordinator GrantTask Node ReleaseTask RequestTask) -set(app_masterworker_files Main Master Worker) -set(app_pingpong_files Main PingPongTask Receiver Sender) -set(app_tokenring_files Main RelayRunner) -set(async_waitall_files Main Receiver Sender) -set(async_yield_files Main Yielder) -set(async_dsend_files Main Receiver Sender) -set(cloud_masterworker_files Main Master Worker) -set(cloud_migration_files Main Daemon Test TestHostOnOff XVM) -set(dht_chord_files Main ChordTask Common FindSuccessorAnswerTask FindSuccessorTask +set(app-bittorrent_files Main Common Connection MessageTask Peer Tracker TrackerTask) +set(app-centralizedmutex_files Main Coordinator GrantTask Node ReleaseTask RequestTask) +set(app-masterworker_files Main Master Worker) +set(app-pingpong_files Main PingPongTask Receiver Sender) +set(app-tokenring_files Main RelayRunner) +set(async-waitall_files Main Receiver Sender) +set(async-yield_files Main Yielder) +set(async-dsend_files Main Receiver Sender) +set(cloud-masterworker_files Main Master Worker) +set(cloud-migration_files Main Daemon Test TestHostOnOff XVM) +set(dht-chord_files Main ChordTask Common FindSuccessorAnswerTask FindSuccessorTask GetPredecessorAnswerTask GetPredecessorTask Node NotifyTask) -set(dht_kademlia_files Main Answer Bucket Common Contact FindNodeAnswerTask FindNodeTask +set(dht-kademlia_files Main Answer Bucket Common Contact FindNodeAnswerTask FindNodeTask KademliaTask Node PingAnswerTask PingTask RoutingTable) -set(trace_pingpong_files Main PingPongTask Receiver Sender) -set(energy_consumption_files Main EnergyConsumer) -set(energy_pstate_files Main PstateRunner) -set(energy_vm_files Main EnergyVMRunner) -set(io_file_files Main Node) -set(io_storage_files Main Client) -set(process_kill_files Main Killer Victim) -set(process_migration_files Main Emigrant Policeman) -set(process_startkilltime_files Main Sleeper) -set(process_suspend_files Main DreamMaster LazyGuy) -set(task_priority_files Main Test) +set(trace-pingpong_files Main PingPongTask Receiver Sender) +set(energy-consumption_files Main EnergyConsumer) +set(energy-pstate_files Main PstateRunner) +set(energy-vm_files Main EnergyVMRunner) +set(io-file_files Main Node) +set(io-storage_files Main Client) +set(process-kill_files Main Killer Victim) +set(process-migration_files Main Emigrant Policeman) +set(process-startkilltime_files Main Sleeper) +set(process-suspend_files Main DreamMaster LazyGuy) +set(task-priority_files Main Test) -foreach (example app_bittorrent app_centralizedmutex app_masterworker app_pingpong app_tokenring async_yield async_waitall async_dsend - cloud_migration cloud_masterworker dht_chord dht_kademlia energy_consumption energy_pstate energy_vm io_file io_storage - process_kill process_migration process_startkilltime process_suspend task_priority trace_pingpong) - string (REPLACE "_" "/" example_dir ${example}) +foreach (example app-bittorrent app-centralizedmutex app-masterworker app-pingpong app-tokenring async-yield async-waitall async-dsend + cloud-migration cloud-masterworker dht-chord dht-kademlia energy-consumption energy-pstate energy-vm io-file io-storage + process-kill process-migration process-startkilltime process-suspend task-priority trace-pingpong) + string (REPLACE "-" "/" example_dir ${example}) set (srcdir ${CMAKE_CURRENT_SOURCE_DIR}/${example_dir}) foreach (filename ${${example}_files} ) set( ${example}_sources "${${example}_sources}" "${srcdir}/${filename}.java") @@ -36,15 +36,15 @@ foreach (example app_bittorrent app_centralizedmutex app_masterworker app_pingpo if(enable_java) add_custom_command( - COMMENT "Building java_${example}..." - OUTPUT ${example_dir}/java_${example}_compiled + COMMENT "Building java-${example}..." + OUTPUT ${example_dir}/java-${example}_compiled DEPENDS ${example_sources} simgrid-java_jar ${SIMGRID_JAR} COMMAND ${CMAKE_COMMAND} -E make_directory ${example_dir} COMMAND ${JAVA_COMPILE} -classpath ${SIMGRID_JAR} -d ${CMAKE_CURRENT_BINARY_DIR} ${${example}_sources} - COMMAND ${CMAKE_COMMAND} -E remove ${example_dir}/java_${example}_compiled - COMMAND ${CMAKE_COMMAND} -E touch ${example_dir}/java_${example}_compiled + COMMAND ${CMAKE_COMMAND} -E remove ${example_dir}/java-${example}_compiled + COMMAND ${CMAKE_COMMAND} -E touch ${example_dir}/java-${example}_compiled ) - add_custom_target(${example} ALL DEPENDS ${example_dir}/java_${example}_compiled) + add_custom_target(java-${example} ALL DEPENDS ${example_dir}/java-${example}_compiled) endif() set(examples_src ${examples_src} ${${example}_sources}) set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/${example_dir}/${example}.tesh) @@ -64,10 +64,10 @@ set(xml_files ${xml_files} ${CMAKE_CURRENT_SOURCE_DIR}/app/bittorrent/bi ${CMAKE_CURRENT_SOURCE_DIR}/task/priority/priority.xml PARENT_SCOPE) if(enable_java) - foreach (example app_bittorrent app_centralizedmutex app_masterworker app_pingpong app_tokenring async_yield async_waitall async_dsend - cloud_migration cloud_masterworker dht_chord dht_kademlia energy_consumption energy_pstate energy_vm io_file io_storage - process_kill process_migration process_startkilltime process_suspend task_priority trace_pingpong) - string (REPLACE "_" "/" example_dir ${example}) + foreach (example app-bittorrent app-centralizedmutex app-masterworker app-pingpong app-tokenring async-yield async-waitall async-dsend + cloud-migration cloud-masterworker dht-chord dht-kademlia energy-consumption energy-pstate energy-vm io-file io-storage + process-kill process-migration process-startkilltime process-suspend task-priority trace-pingpong) + string (REPLACE "-" "/" example_dir ${example}) ADD_TESH(java-${example} --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/java --setenv LD_LIBRARY_PATH=${CMAKE_BINARY_DIR}/lib --setenv classpath=${TESH_CLASSPATH} --cd ${CMAKE_BINARY_DIR}/examples/java/${example_dir} ${CMAKE_HOME_DIRECTORY}/examples/java/${example_dir}/${example}.tesh) endforeach() endif()