build: CMake refactoring
Includes:
- refactor build_lib and build_lib_example macros
- unify src and contrib macros
- replace macro with function not to leak definitions
- parse list of arguments
- different cmake-format file for modules to list one item per line
This commit is contained in:
36
buildsupport/cmake-format-modules.txt
Normal file
36
buildsupport/cmake-format-modules.txt
Normal file
@@ -0,0 +1,36 @@
|
||||
additional_commands:
|
||||
build_lib:
|
||||
flags: [IGNORE_PCH]
|
||||
kwargs:
|
||||
LIBNAME : '1'
|
||||
SOURCE_FILES : '*'
|
||||
HEADER_FILES : '*'
|
||||
LIBRARIES_TO_LINK : '*'
|
||||
TEST_SOURCES : '*'
|
||||
DEPRECATED_HEADER_FILES : '*'
|
||||
MODULE_ENABLED_FEATURES : '*'
|
||||
|
||||
build_lib_example:
|
||||
flags: [IGNORE_PCH]
|
||||
kwargs:
|
||||
NAME : '1'
|
||||
SOURCE_FILES : '*'
|
||||
HEADER_FILES : '*'
|
||||
LIBRARIES_TO_LINK : '*'
|
||||
|
||||
build_example:
|
||||
kwargs:
|
||||
NAME : '1'
|
||||
SOURCE_FILES : '*'
|
||||
HEADER_FILES : '*'
|
||||
LIBRARIES_TO_LINK : '*'
|
||||
|
||||
format:
|
||||
tab_size: 2
|
||||
line_width: 80
|
||||
dangle_parens: true
|
||||
autosort: true
|
||||
enable_sort: true
|
||||
max_subgroups_hwrap: 1
|
||||
max_pargs_hwrap: 1
|
||||
max_lines_hwrap: 1
|
||||
@@ -3,4 +3,5 @@ format:
|
||||
line_width: 80
|
||||
dangle_parens: true
|
||||
autosort: true
|
||||
max_subgroups_hwrap: 3
|
||||
enable_sort: true
|
||||
max_subgroups_hwrap: 3
|
||||
|
||||
@@ -36,27 +36,3 @@ macro(process_contribution contribution_list)
|
||||
endif()
|
||||
endforeach()
|
||||
endmacro()
|
||||
|
||||
# cmake-format: off
|
||||
macro(
|
||||
build_contrib_example
|
||||
name
|
||||
source_files
|
||||
header_files
|
||||
libraries_to_link
|
||||
)
|
||||
# cmake-format: on
|
||||
build_lib_example_impl(
|
||||
"contrib/${contribname}" "${name}" "${source_files}" "${header_files}"
|
||||
"${libraries_to_link}"
|
||||
)
|
||||
endmacro()
|
||||
|
||||
macro(build_contrib_lib name source_files header_files libraries_to_link
|
||||
test_sources
|
||||
)
|
||||
build_lib_impl(
|
||||
"contrib" "${name}" "${source_files}" "${header_files}"
|
||||
"${libraries_to_link}" "${test_sources}"
|
||||
)
|
||||
endmacro()
|
||||
|
||||
@@ -20,39 +20,40 @@
|
||||
# This macro processes a ns-3 module
|
||||
#
|
||||
# Arguments:
|
||||
# folder = src or contrib/contributor_module
|
||||
# libname = core, wifi, contributor_module
|
||||
# source_files = "list;of;.cc;files;"
|
||||
# header_files = "list;of;public;.h;files;"
|
||||
# libraries_to_link = "list;of;${library_names};"
|
||||
# test_sources = "list;of;.cc;test;files;"
|
||||
# LIBNAME = core, wifi, contributor_module
|
||||
# SOURCE_FILES = "list;of;.cc;files;"
|
||||
# HEADER_FILES = "list;of;public;.h;files;"
|
||||
# LIBRARIES_TO_LINK = "list;of;${library_names};"
|
||||
# TEST_SOURCES = "list;of;.cc;test;files;"
|
||||
#
|
||||
# Hidden argument (this is not a function, so you don't really need to pass arguments explicitly)
|
||||
# deprecated_header_files = "list;of;deprecated;.h;files", copy won't get triggered if deprecated_header_files isn't set
|
||||
# ignore_pch = TRUE or FALSE, prevents the PCH from including undesired system libraries (e.g. custom GLIBC for DCE)
|
||||
# module_enabled_features = "list;of;enabled;features;for;this;module" (used by fd-net-device)
|
||||
# DEPRECATED_HEADER_FILES = "list;of;deprecated;.h;files", copy won't get triggered if DEPRECATED_HEADER_FILES isn't set
|
||||
# IGNORE_PCH = TRUE or FALSE, prevents the PCH from including undesired system libraries (e.g. custom GLIBC for DCE)
|
||||
# MODULE_ENABLED_FEATURES = "list;of;enabled;features;for;this;module" (used by fd-net-device)
|
||||
# cmake-format: on
|
||||
|
||||
macro(
|
||||
build_lib_impl
|
||||
folder
|
||||
libname
|
||||
source_files
|
||||
header_files
|
||||
libraries_to_link
|
||||
test_sources
|
||||
#deprecated_header_files
|
||||
#ignore_pch
|
||||
#module_enabled_features
|
||||
)
|
||||
# cmake-format: on
|
||||
function(build_lib)
|
||||
# Argument parsing
|
||||
set(options IGNORE_PCH)
|
||||
set(oneValueArgs LIBNAME)
|
||||
set(multiValueArgs SOURCE_FILES HEADER_FILES LIBRARIES_TO_LINK TEST_SOURCES
|
||||
DEPRECATED_HEADER_FILES MODULE_ENABLED_FEATURES
|
||||
)
|
||||
cmake_parse_arguments(
|
||||
"BLIB" "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN}
|
||||
)
|
||||
|
||||
# Get path src/module or contrib/module
|
||||
string(REPLACE "${PROJECT_SOURCE_DIR}/" "" FOLDER
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}"
|
||||
)
|
||||
|
||||
# Add library to a global list of libraries
|
||||
if("${folder}" MATCHES "src")
|
||||
set(ns3-libs "${lib${libname}};${ns3-libs}"
|
||||
if("${FOLDER}" MATCHES "src")
|
||||
set(ns3-libs "${lib${BLIB_LIBNAME}};${ns3-libs}"
|
||||
CACHE INTERNAL "list of processed upstream modules"
|
||||
)
|
||||
else()
|
||||
set(ns3-contrib-libs "${lib${libname}};${ns3-contrib-libs}"
|
||||
set(ns3-contrib-libs "${lib${BLIB_LIBNAME}};${ns3-contrib-libs}"
|
||||
CACHE INTERNAL "list of processed contrib modules"
|
||||
)
|
||||
endif()
|
||||
@@ -60,29 +61,34 @@ macro(
|
||||
if(NOT ${XCODE})
|
||||
# Create object library with sources and headers, that will be used in
|
||||
# lib-ns3-static and the shared library
|
||||
add_library(${lib${libname}-obj} OBJECT "${source_files}" "${header_files}")
|
||||
add_library(
|
||||
${lib${BLIB_LIBNAME}-obj} OBJECT "${BLIB_SOURCE_FILES}"
|
||||
"${BLIB_HEADER_FILES}"
|
||||
)
|
||||
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${ignore_pch}))
|
||||
target_precompile_headers(${lib${libname}-obj} REUSE_FROM stdlib_pch)
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${IGNORE_PCH}))
|
||||
target_precompile_headers(${lib${BLIB_LIBNAME}-obj} REUSE_FROM stdlib_pch)
|
||||
endif()
|
||||
|
||||
# Create shared library with previously created object library (saving
|
||||
# compilation time for static libraries)
|
||||
add_library(${lib${libname}} SHARED $<TARGET_OBJECTS:${lib${libname}-obj}>)
|
||||
add_library(
|
||||
${lib${BLIB_LIBNAME}} SHARED $<TARGET_OBJECTS:${lib${BLIB_LIBNAME}-obj}>
|
||||
)
|
||||
else()
|
||||
# Xcode and CMake don't play well when using object libraries, so we have a
|
||||
# specific path for that
|
||||
add_library(${lib${libname}} SHARED "${source_files}")
|
||||
add_library(${lib${BLIB_LIBNAME}} SHARED "${BLIB_SOURCE_FILES}")
|
||||
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${ignore_pch}))
|
||||
target_precompile_headers(${lib${libname}} REUSE_FROM stdlib_pch)
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${IGNORE_PCH}))
|
||||
target_precompile_headers(${lib${BLIB_LIBNAME}} REUSE_FROM stdlib_pch)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_library(ns3::${lib${libname}} ALIAS ${lib${libname}})
|
||||
add_library(ns3::${lib${BLIB_LIBNAME}} ALIAS ${lib${BLIB_LIBNAME}})
|
||||
|
||||
# Associate public headers with library for installation purposes
|
||||
if("${libname}" STREQUAL "core")
|
||||
if("${BLIB_LIBNAME}" STREQUAL "core")
|
||||
set(config_headers ${CMAKE_HEADER_OUTPUT_DIRECTORY}/config-store-config.h
|
||||
${CMAKE_HEADER_OUTPUT_DIRECTORY}/core-config.h
|
||||
)
|
||||
@@ -93,21 +99,21 @@ macro(
|
||||
endif()
|
||||
endif()
|
||||
set_target_properties(
|
||||
${lib${libname}}
|
||||
${lib${BLIB_LIBNAME}}
|
||||
PROPERTIES
|
||||
PUBLIC_HEADER
|
||||
"${header_files};${deprecated_header_files};${config_headers};${CMAKE_HEADER_OUTPUT_DIRECTORY}/${libname}-module.h"
|
||||
"${BLIB_HEADER_FILES};${BLIB_DEPRECATED_HEADER_FILES};${config_headers};${CMAKE_HEADER_OUTPUT_DIRECTORY}/${BLIB_LIBNAME}-module.h"
|
||||
)
|
||||
|
||||
if(${NS3_CLANG_TIMETRACE})
|
||||
add_dependencies(timeTraceReport ${lib${libname}})
|
||||
add_dependencies(timeTraceReport ${lib${BLIB_LIBNAME}})
|
||||
endif()
|
||||
|
||||
# Split ns and non-ns libraries to manage their propagation properly
|
||||
set(non_ns_libraries_to_link)
|
||||
set(ns_libraries_to_link)
|
||||
|
||||
foreach(library ${libraries_to_link})
|
||||
foreach(library ${BLIB_LIBRARIES_TO_LINK})
|
||||
# Remove lib prefix from module name (e.g. libcore -> core)
|
||||
string(REPLACE "lib" "" module_name "${library}")
|
||||
if(${module_name} IN_LIST ns3-all-enabled-modules)
|
||||
@@ -143,7 +149,7 @@ macro(
|
||||
# with NS3_REEXPORT_THIRD_PARTY_LIBRARIES, we export all 3rd-party library
|
||||
# include directories, allowing consumers of this module to include and link
|
||||
# the 3rd-party code with no additional setup
|
||||
get_target_includes(${lib${libname}} exported_include_directories)
|
||||
get_target_includes(${lib${BLIB_LIBNAME}} exported_include_directories)
|
||||
string(REPLACE "-I" "" exported_include_directories
|
||||
"${exported_include_directories}"
|
||||
)
|
||||
@@ -154,13 +160,13 @@ macro(
|
||||
endif()
|
||||
|
||||
target_link_libraries(
|
||||
${lib${libname}} ${exported_libraries} ${private_libraries}
|
||||
${lib${BLIB_LIBNAME}} ${exported_libraries} ${private_libraries}
|
||||
)
|
||||
|
||||
# set output name of library
|
||||
set_target_properties(
|
||||
${lib${libname}} PROPERTIES OUTPUT_NAME
|
||||
ns${NS3_VER}-${libname}${build_profile_suffix}
|
||||
${lib${BLIB_LIBNAME}}
|
||||
PROPERTIES OUTPUT_NAME ns${NS3_VER}-${BLIB_LIBNAME}${build_profile_suffix}
|
||||
)
|
||||
|
||||
# export include directories used by this library so that it can be used by
|
||||
@@ -168,8 +174,9 @@ macro(
|
||||
# add the build/include path to them, so that they can ns-3 headers with
|
||||
# <ns3/something.h>
|
||||
target_include_directories(
|
||||
${lib${libname}} PUBLIC $<BUILD_INTERFACE:${CMAKE_OUTPUT_DIRECTORY}/include>
|
||||
$<INSTALL_INTERFACE:include>
|
||||
${lib${BLIB_LIBNAME}}
|
||||
PUBLIC $<BUILD_INTERFACE:${CMAKE_OUTPUT_DIRECTORY}/include>
|
||||
$<INSTALL_INTERFACE:include>
|
||||
INTERFACE ${exported_include_directories}
|
||||
)
|
||||
|
||||
@@ -179,7 +186,7 @@ macro(
|
||||
)
|
||||
if(${NS3_STATIC} OR ${NS3_MONOLIB})
|
||||
set(lib-ns3-static-objs
|
||||
"$<TARGET_OBJECTS:${lib${libname}-obj}>;${lib-ns3-static-objs}"
|
||||
"$<TARGET_OBJECTS:${lib${BLIB_LIBNAME}-obj}>;${lib-ns3-static-objs}"
|
||||
CACHE
|
||||
INTERNAL
|
||||
"list of object files from module used by NS3_STATIC and NS3_MONOLIB"
|
||||
@@ -187,55 +194,56 @@ macro(
|
||||
endif()
|
||||
|
||||
# Write a module header that includes all headers from that module
|
||||
write_module_header("${libname}" "${header_files}")
|
||||
write_module_header("${BLIB_LIBNAME}" "${BLIB_HEADER_FILES}")
|
||||
|
||||
# Copy all header files to outputfolder/include before each build
|
||||
copy_headers_before_building_lib(
|
||||
${libname} ${CMAKE_HEADER_OUTPUT_DIRECTORY} "${header_files}" public
|
||||
${BLIB_LIBNAME} ${CMAKE_HEADER_OUTPUT_DIRECTORY} "${BLIB_HEADER_FILES}"
|
||||
public
|
||||
)
|
||||
if(deprecated_header_files)
|
||||
if(BLIB_DEPRECATED_HEADER_FILES)
|
||||
copy_headers_before_building_lib(
|
||||
${libname} ${CMAKE_HEADER_OUTPUT_DIRECTORY} "${deprecated_header_files}"
|
||||
deprecated
|
||||
${BLIB_LIBNAME} ${CMAKE_HEADER_OUTPUT_DIRECTORY}
|
||||
"${BLIB_DEPRECATED_HEADER_FILES}" deprecated
|
||||
)
|
||||
endif()
|
||||
|
||||
# Build tests if requested
|
||||
if(${ENABLE_TESTS})
|
||||
list(LENGTH test_sources test_source_len)
|
||||
list(LENGTH BLIB_TEST_SOURCES test_source_len)
|
||||
if(${test_source_len} GREATER 0)
|
||||
# Create libname of output library test of module
|
||||
set(test${libname} lib${libname}-test CACHE INTERNAL "")
|
||||
set(ns3-libs-tests "${test${libname}};${ns3-libs-tests}"
|
||||
# Create BLIB_LIBNAME of output library test of module
|
||||
set(test${BLIB_LIBNAME} lib${BLIB_LIBNAME}-test CACHE INTERNAL "")
|
||||
set(ns3-libs-tests "${test${BLIB_LIBNAME}};${ns3-libs-tests}"
|
||||
CACHE INTERNAL "list of test libraries"
|
||||
)
|
||||
|
||||
# Create shared library containing tests of the module
|
||||
add_library(${test${libname}} SHARED "${test_sources}")
|
||||
add_library(${test${BLIB_LIBNAME}} SHARED "${BLIB_TEST_SOURCES}")
|
||||
|
||||
# Link test library to the module library
|
||||
if(${NS3_MONOLIB})
|
||||
target_link_libraries(
|
||||
${test${libname}} ${LIB_AS_NEEDED_PRE} ${lib-ns3-monolib}
|
||||
${test${BLIB_LIBNAME}} ${LIB_AS_NEEDED_PRE} ${lib-ns3-monolib}
|
||||
${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
else()
|
||||
target_link_libraries(
|
||||
${test${libname}} ${LIB_AS_NEEDED_PRE} ${lib${libname}}
|
||||
"${libraries_to_link}" ${LIB_AS_NEEDED_POST}
|
||||
${test${BLIB_LIBNAME}} ${LIB_AS_NEEDED_PRE} ${lib${BLIB_LIBNAME}}
|
||||
"${BLIB_LIBRARIES_TO_LINK}" ${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
endif()
|
||||
set_target_properties(
|
||||
${test${libname}}
|
||||
${test${BLIB_LIBNAME}}
|
||||
PROPERTIES OUTPUT_NAME
|
||||
ns${NS3_VER}-${libname}-test${build_profile_suffix}
|
||||
ns${NS3_VER}-${BLIB_LIBNAME}-test${build_profile_suffix}
|
||||
)
|
||||
|
||||
target_compile_definitions(
|
||||
${test${libname}} PRIVATE NS_TEST_SOURCEDIR="${folder}/${libname}/test"
|
||||
${test${BLIB_LIBNAME}} PRIVATE NS_TEST_SOURCEDIR="${FOLDER}/test"
|
||||
)
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${ignore_pch}))
|
||||
target_precompile_headers(${test${libname}} REUSE_FROM stdlib_pch)
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${IGNORE_PCH}))
|
||||
target_precompile_headers(${test${BLIB_LIBNAME}} REUSE_FROM stdlib_pch)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
@@ -263,11 +271,9 @@ macro(
|
||||
|
||||
# Add target to scan python bindings
|
||||
if(${ENABLE_SCAN_PYTHON_BINDINGS}
|
||||
AND EXISTS ${CMAKE_HEADER_OUTPUT_DIRECTORY}/${libname}-module.h
|
||||
AND EXISTS ${CMAKE_HEADER_OUTPUT_DIRECTORY}/${BLIB_LIBNAME}-module.h
|
||||
)
|
||||
set(bindings_output_folder
|
||||
${PROJECT_SOURCE_DIR}/${folder}/${libname}/bindings
|
||||
)
|
||||
set(bindings_output_folder ${PROJECT_SOURCE_DIR}/${FOLDER}/bindings)
|
||||
file(MAKE_DIRECTORY ${bindings_output_folder})
|
||||
set(module_api_ILP32 ${bindings_output_folder}/modulegen__gcc_ILP32.py)
|
||||
set(module_api_LP64 ${bindings_output_folder}/modulegen__gcc_LP64.py)
|
||||
@@ -279,12 +285,12 @@ macro(
|
||||
|
||||
set(header_map "")
|
||||
# We need a python map that takes header.h to module e.g. "ptr.h": "core"
|
||||
foreach(header ${header_files})
|
||||
foreach(header ${BLIB_HEADER_FILES})
|
||||
# header is a relative path to the current working directory
|
||||
get_filename_component(
|
||||
header_name ${CMAKE_CURRENT_SOURCE_DIR}/${header} NAME
|
||||
)
|
||||
string(APPEND header_map "\"${header_name}\":\"${libname}\",")
|
||||
string(APPEND header_map "\"${header_name}\":\"${BLIB_LIBNAME}\",")
|
||||
endforeach()
|
||||
|
||||
set(ns3-headers-to-module-map "${ns3-headers-to-module-map}${header_map}"
|
||||
@@ -292,7 +298,7 @@ macro(
|
||||
)
|
||||
|
||||
# API scan needs the include directories to find a few headers (e.g. mpi.h)
|
||||
get_target_includes(${lib${libname}} modulegen_include_dirs)
|
||||
get_target_includes(${lib${BLIB_LIBNAME}} modulegen_include_dirs)
|
||||
|
||||
set(module_to_generate_api ${module_api_ILP32})
|
||||
set(LP64toILP32)
|
||||
@@ -306,40 +312,38 @@ macro(
|
||||
endif()
|
||||
|
||||
add_custom_target(
|
||||
${lib${libname}}-apiscan
|
||||
${lib${BLIB_LIBNAME}}-apiscan
|
||||
COMMAND
|
||||
${modulescan_modular_command} ${CMAKE_OUTPUT_DIRECTORY} ${libname}
|
||||
${modulescan_modular_command} ${CMAKE_OUTPUT_DIRECTORY} ${BLIB_LIBNAME}
|
||||
${PROJECT_BINARY_DIR}/header_map.json ${module_to_generate_api}
|
||||
\"${arch_flags} ${modulegen_include_dirs}\"
|
||||
COMMAND ${LP64toILP32}
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
DEPENDS ${lib${libname}}
|
||||
DEPENDS ${lib${BLIB_LIBNAME}}
|
||||
)
|
||||
add_dependencies(apiscan-all ${lib${libname}}-apiscan)
|
||||
add_dependencies(apiscan-all ${lib${BLIB_LIBNAME}}-apiscan)
|
||||
endif()
|
||||
|
||||
# Build pybindings if requested and if bindings subfolder exists in
|
||||
# NS3/src/libname
|
||||
# NS3/src/BLIB_LIBNAME
|
||||
if(${ENABLE_PYTHON_BINDINGS} AND EXISTS
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/bindings"
|
||||
)
|
||||
set(bindings_output_folder
|
||||
${CMAKE_OUTPUT_DIRECTORY}/${folder}/${libname}/bindings
|
||||
)
|
||||
set(bindings_output_folder ${CMAKE_OUTPUT_DIRECTORY}/${FOLDER}/bindings)
|
||||
file(MAKE_DIRECTORY ${bindings_output_folder})
|
||||
set(module_src ${bindings_output_folder}/ns3module.cc)
|
||||
set(module_hdr ${bindings_output_folder}/ns3module.h)
|
||||
|
||||
string(REPLACE "-" "_" libname_sub ${libname}) # '-' causes problems (e.g.
|
||||
# csma-layout), replace with
|
||||
# '_' (e.g. csma_layout)
|
||||
string(REPLACE "-" "_" BLIB_LIBNAME_sub ${BLIB_LIBNAME}) # '-' causes
|
||||
# problems (e.g.
|
||||
# csma-layout), replace with '_' (e.g. csma_layout)
|
||||
|
||||
# Set prefix of binding to _ if a ${libname}.py exists, and copy the
|
||||
# ${libname}.py to the output folder
|
||||
# Set prefix of binding to _ if a ${BLIB_LIBNAME}.py exists, and copy the
|
||||
# ${BLIB_LIBNAME}.py to the output folder
|
||||
set(prefix)
|
||||
if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/bindings/${libname}.py)
|
||||
if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/bindings/${BLIB_LIBNAME}.py)
|
||||
set(prefix _)
|
||||
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/bindings/${libname}.py
|
||||
file(COPY ${CMAKE_CURRENT_SOURCE_DIR}/bindings/${BLIB_LIBNAME}.py
|
||||
DESTINATION ${CMAKE_OUTPUT_DIRECTORY}/bindings/python/ns
|
||||
)
|
||||
endif()
|
||||
@@ -349,7 +353,7 @@ macro(
|
||||
# force
|
||||
# reprocessing
|
||||
string(REPLACE ";" "," ENABLED_FEATURES
|
||||
"${ns3-libs};${module_enabled_features}"
|
||||
"${ns3-libs};${BLIB_MODULE_ENABLED_FEATURES}"
|
||||
)
|
||||
set(modulegen_modular_command
|
||||
GCC_RTTI_ABI_COMPLETE=True NS3_ENABLED_FEATURES="${ENABLED_FEATURES}"
|
||||
@@ -361,7 +365,7 @@ macro(
|
||||
${CMAKE_COMMAND} -E env
|
||||
PYTHONPATH=${CMAKE_OUTPUT_DIRECTORY}:$ENV{PYTHONPATH}
|
||||
${modulegen_modular_command} ${CMAKE_CURRENT_SOURCE_DIR} ${arch}
|
||||
${prefix}${libname_sub} ${module_src}
|
||||
${prefix}${BLIB_LIBNAME_sub} ${module_src}
|
||||
TIMEOUT 60
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||
OUTPUT_FILE ${module_hdr}
|
||||
@@ -371,7 +375,7 @@ macro(
|
||||
if(${error_code} OR NOT (EXISTS ${module_hdr}))
|
||||
message(
|
||||
FATAL_ERROR
|
||||
"Something went wrong during processing of the python bindings of module ${libname}."
|
||||
"Something went wrong during processing of the python bindings of module ${BLIB_LIBNAME}."
|
||||
" Make sure you have the latest version of Pybindgen."
|
||||
)
|
||||
if(EXISTS ${module_src})
|
||||
@@ -382,13 +386,13 @@ macro(
|
||||
|
||||
# Add core module helper sources
|
||||
set(python_module_files ${module_hdr} ${module_src})
|
||||
if(${libname} STREQUAL "core")
|
||||
if(${BLIB_LIBNAME} STREQUAL "core")
|
||||
list(APPEND python_module_files
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/bindings/module_helpers.cc
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/bindings/scan-header.h
|
||||
)
|
||||
endif()
|
||||
set(bindings-name lib${libname}-bindings)
|
||||
set(bindings-name lib${BLIB_LIBNAME}-bindings)
|
||||
add_library(${bindings-name} SHARED "${python_module_files}")
|
||||
target_include_directories(
|
||||
${bindings-name} PUBLIC ${Python_INCLUDE_DIRS} ${bindings_output_folder}
|
||||
@@ -396,7 +400,7 @@ macro(
|
||||
target_compile_options(${bindings-name} PRIVATE -Wno-error)
|
||||
|
||||
# If there is any, remove the "lib" prefix of libraries (search for
|
||||
# "set(lib${libname}")
|
||||
# "set(lib${BLIB_LIBNAME}")
|
||||
list(LENGTH ns_libraries_to_link num_libraries)
|
||||
if(num_libraries GREATER "0")
|
||||
string(REPLACE ";" "-bindings;" bindings_to_link
|
||||
@@ -405,8 +409,8 @@ macro(
|
||||
endif()
|
||||
target_link_libraries(
|
||||
${bindings-name}
|
||||
PUBLIC ${LIB_AS_NEEDED_PRE} ${lib${libname}} "${bindings_to_link}"
|
||||
"${libraries_to_link}" ${LIB_AS_NEEDED_POST}
|
||||
PUBLIC ${LIB_AS_NEEDED_PRE} ${lib${BLIB_LIBNAME}} "${bindings_to_link}"
|
||||
"${BLIB_LIBRARIES_TO_LINK}" ${LIB_AS_NEEDED_POST}
|
||||
PRIVATE ${Python_LIBRARIES}
|
||||
)
|
||||
target_include_directories(
|
||||
@@ -423,7 +427,7 @@ macro(
|
||||
# Set binding library name and output folder
|
||||
set_target_properties(
|
||||
${bindings-name}
|
||||
PROPERTIES OUTPUT_NAME ${prefix}${libname_sub}
|
||||
PROPERTIES OUTPUT_NAME ${prefix}${BLIB_LIBNAME_sub}
|
||||
PREFIX ""
|
||||
${suffix} LIBRARY_OUTPUT_DIRECTORY
|
||||
${CMAKE_OUTPUT_DIRECTORY}/bindings/python/ns
|
||||
@@ -437,7 +441,7 @@ macro(
|
||||
# Make sure all bindings are built before building the visualizer module
|
||||
# that makes use of them
|
||||
if(${ENABLE_VISUALIZER})
|
||||
if(NOT (${name} STREQUAL visualizer))
|
||||
if(NOT (${BLIB_LIBNAME} STREQUAL visualizer))
|
||||
add_dependencies(${libvisualizer} ${bindings-name})
|
||||
endif()
|
||||
endif()
|
||||
@@ -445,39 +449,42 @@ macro(
|
||||
|
||||
# Handle package export
|
||||
install(
|
||||
TARGETS ${lib${name}}
|
||||
TARGETS ${lib${BLIB_LIBNAME}}
|
||||
EXPORT ns3ExportTargets
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}/
|
||||
PUBLIC_HEADER DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/ns3"
|
||||
)
|
||||
if(${NS3_VERBOSE})
|
||||
message(STATUS "Processed ${folder}/${libname}")
|
||||
message(STATUS "Processed ${FOLDER}")
|
||||
endif()
|
||||
endmacro()
|
||||
endfunction()
|
||||
|
||||
# cmake-format: off
|
||||
#
|
||||
# This macro processes a ns-3 module example
|
||||
#
|
||||
# Arguments: folder = src or contrib/contributor_module libname = core, wifi, contributor_module (this is implicit, as
|
||||
# it is called by build_lib_impl)
|
||||
# name = example name (e.g. command-line-example)
|
||||
# source_files = "cmake;list;of;.cc;files;"
|
||||
# header_files = "cmake;list;of;public;.h;files;"
|
||||
# libraries_to_link = "cmake;list;of;${library_names};"
|
||||
# Arguments:
|
||||
# NAME = example name (e.g. command-line-example)
|
||||
# LIBNAME = parent library (e.g. core)
|
||||
# SOURCE_FILES = "cmake;list;of;.cc;files;"
|
||||
# HEADER_FILES = "cmake;list;of;public;.h;files;"
|
||||
# LIBRARIES_TO_LINK = "cmake;list;of;${library_names};"
|
||||
#
|
||||
macro(
|
||||
build_lib_example_impl
|
||||
folder
|
||||
name
|
||||
source_files
|
||||
header_files
|
||||
libraries_to_link
|
||||
)
|
||||
function(build_lib_example)
|
||||
# Argument parsing
|
||||
set(options IGNORE_PCH)
|
||||
set(oneValueArgs NAME)
|
||||
set(multiValueArgs SOURCE_FILES HEADER_FILES LIBRARIES_TO_LINK)
|
||||
cmake_parse_arguments("BLIB_EXAMPLE" "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
|
||||
|
||||
# Get path src/module or contrib/module
|
||||
string(REPLACE "${PROJECT_SOURCE_DIR}/" "" FOLDER "${CMAKE_CURRENT_SOURCE_DIR}")
|
||||
get_filename_component(FOLDER ${FOLDER} DIRECTORY)
|
||||
|
||||
# cmake-format: on
|
||||
set(missing_dependencies FALSE)
|
||||
foreach(lib ${libraries_to_link})
|
||||
foreach(lib ${BLIB_EXAMPLE_LIBRARIES_TO_LINK})
|
||||
# skip check for ns-3 modules if its a path to a library
|
||||
if(EXISTS ${lib})
|
||||
continue()
|
||||
@@ -492,40 +499,46 @@ macro(
|
||||
|
||||
if(NOT missing_dependencies)
|
||||
# Create shared library with sources and headers
|
||||
add_executable(${name} "${source_files}" "${header_files}")
|
||||
add_executable(
|
||||
"${BLIB_EXAMPLE_NAME}" ${BLIB_EXAMPLE_SOURCE_FILES}
|
||||
${BLIB_EXAMPLE_HEADER_FILES}
|
||||
)
|
||||
|
||||
if(${NS3_STATIC})
|
||||
target_link_libraries(
|
||||
${name} ${LIB_AS_NEEDED_PRE_STATIC} ${lib-ns3-static}
|
||||
${BLIB_EXAMPLE_NAME} ${LIB_AS_NEEDED_PRE_STATIC} ${lib-ns3-static}
|
||||
)
|
||||
elseif(${NS3_MONOLIB})
|
||||
target_link_libraries(
|
||||
${name} ${LIB_AS_NEEDED_PRE} ${lib-ns3-monolib} ${LIB_AS_NEEDED_POST}
|
||||
${BLIB_EXAMPLE_NAME} ${LIB_AS_NEEDED_PRE} ${lib-ns3-monolib}
|
||||
${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
else()
|
||||
target_link_libraries(
|
||||
${name} ${LIB_AS_NEEDED_PRE} ${lib${libname}} ${libraries_to_link}
|
||||
${optional_visualizer_lib} ${LIB_AS_NEEDED_POST}
|
||||
${BLIB_EXAMPLE_NAME} ${LIB_AS_NEEDED_PRE} ${lib${BLIB_EXAMPLE_LIBNAME}}
|
||||
${BLIB_EXAMPLE_LIBRARIES_TO_LINK} ${optional_visualizer_lib}
|
||||
${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${ignore_pch}))
|
||||
target_precompile_headers(${name} REUSE_FROM stdlib_pch_exec)
|
||||
if(${PRECOMPILE_HEADERS_ENABLED} AND (NOT ${BLIB_EXAMPLE_IGNORE_PCH}))
|
||||
target_precompile_headers(${BLIB_EXAMPLE_NAME} REUSE_FROM stdlib_pch_exec)
|
||||
endif()
|
||||
|
||||
set_runtime_outputdirectory(
|
||||
${name} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${folder}/examples/ ""
|
||||
${BLIB_EXAMPLE_NAME}
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${FOLDER}/examples/ ""
|
||||
)
|
||||
endif()
|
||||
endmacro()
|
||||
endfunction()
|
||||
|
||||
# This macro processes a ns-3 module header file (module_name-module.h)
|
||||
#
|
||||
# Arguments: name = module name (e.g. core, wifi) header_files =
|
||||
# Arguments: name = module name (e.g. core, wifi) HEADER_FILES =
|
||||
# "cmake;list;of;public;.h;files;"
|
||||
macro(write_module_header name header_files)
|
||||
string(TOUPPER ${name} uppercase_name)
|
||||
string(REPLACE "-" "_" final_name ${uppercase_name})
|
||||
function(write_module_header name header_files)
|
||||
string(TOUPPER "${name}" uppercase_name)
|
||||
string(REPLACE "-" "_" final_name "${uppercase_name}")
|
||||
# Common module_header
|
||||
list(APPEND contents "#ifdef NS3_MODULE_COMPILATION ")
|
||||
list(
|
||||
@@ -559,4 +572,4 @@ macro(write_module_header name header_files)
|
||||
#endif "
|
||||
)
|
||||
file(WRITE ${CMAKE_HEADER_OUTPUT_DIRECTORY}/${name}-module.h ${contents})
|
||||
endmacro()
|
||||
endfunction()
|
||||
|
||||
@@ -412,15 +412,21 @@ macro(process_options)
|
||||
mark_as_advanced(CMAKE_FORMAT_PROGRAM)
|
||||
find_program(CMAKE_FORMAT_PROGRAM cmake-format HINTS ~/.local/bin)
|
||||
if(CMAKE_FORMAT_PROGRAM)
|
||||
file(GLOB_RECURSE ALL_CMAKE_FILES CMakeLists.txt buildsupport/*.cmake)
|
||||
file(GLOB_RECURSE MODULES_CMAKE_FILES src/**/CMakeLists.txt contrib/**/CMakeLists.txt examples/**/CMakeLists.txt)
|
||||
file(GLOB INTERNAL_CMAKE_FILES CMakeLists.txt utils/**/CMakeLists.txt src/CMakeLists.txt buildsupport/**/*.cmake)
|
||||
add_custom_target(
|
||||
cmake-format
|
||||
COMMAND
|
||||
${CMAKE_FORMAT_PROGRAM} -c
|
||||
${PROJECT_SOURCE_DIR}/buildsupport/cmake-format.txt -i
|
||||
${ALL_CMAKE_FILES}
|
||||
${INTERNAL_CMAKE_FILES}
|
||||
COMMAND
|
||||
${CMAKE_FORMAT_PROGRAM} -c
|
||||
${PROJECT_SOURCE_DIR}/buildsupport/cmake-format-modules.txt -i
|
||||
${MODULES_CMAKE_FILES}
|
||||
)
|
||||
unset(ALL_CMAKE_FILES)
|
||||
unset(MODULES_CMAKE_FILES)
|
||||
unset(INTERNAL_CMAKE_FILES)
|
||||
endif()
|
||||
|
||||
# If the user has not set a CXX standard version, assume the minimum
|
||||
@@ -868,8 +874,8 @@ macro(process_options)
|
||||
|
||||
function(sphinx_target targetname)
|
||||
add_custom_target(
|
||||
sphinx_${targetname} COMMAND make SPHINXOPTS=-N -k html singlehtml
|
||||
latexpdf
|
||||
sphinx_${targetname}
|
||||
COMMAND make SPHINXOPTS=-N -k html singlehtml latexpdf
|
||||
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}/doc/${targetname}
|
||||
)
|
||||
add_dependencies(sphinx sphinx_${targetname})
|
||||
@@ -1074,7 +1080,8 @@ macro(process_options)
|
||||
if(${NS3_NETANIM})
|
||||
include(FetchContent)
|
||||
FetchContent_Declare(
|
||||
netanim GIT_REPOSITORY https://gitlab.com/nsnam/netanim.git
|
||||
netanim
|
||||
GIT_REPOSITORY https://gitlab.com/nsnam/netanim.git
|
||||
GIT_TAG netanim-3.108
|
||||
)
|
||||
FetchContent_Populate(netanim)
|
||||
@@ -1145,27 +1152,16 @@ endfunction(copy_headers_before_building_lib)
|
||||
# Import macros used for modules and define specialized versions for src modules
|
||||
include(buildsupport/custom_modules/ns3_module_macros.cmake)
|
||||
|
||||
macro(build_lib libname source_files header_files libraries_to_link
|
||||
test_sources
|
||||
)
|
||||
build_lib_impl(
|
||||
"src" "${libname}" "${source_files}" "${header_files}"
|
||||
"${libraries_to_link}" "${test_sources}"
|
||||
)
|
||||
endmacro()
|
||||
|
||||
macro(build_lib_example name source_files header_files libraries_to_link)
|
||||
build_lib_example_impl(
|
||||
"src/${libname}" "${name}" "${source_files}" "${header_files}"
|
||||
"${libraries_to_link}"
|
||||
)
|
||||
endmacro()
|
||||
|
||||
# Contrib modules counterparts of macros above
|
||||
include(buildsupport/custom_modules/ns3_contributions.cmake)
|
||||
|
||||
# Macro to build examples in ns-3-dev/examples/
|
||||
macro(build_example name source_files header_files libraries_to_link)
|
||||
macro(build_example)
|
||||
set(options)
|
||||
set(oneValueArgs NAME)
|
||||
set(multiValueArgs SOURCE_FILES HEADER_FILES LIBRARIES_TO_LINK)
|
||||
cmake_parse_arguments("EXAMPLE" "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
|
||||
|
||||
set(missing_dependencies FALSE)
|
||||
foreach(lib ${libraries_to_link})
|
||||
string(REPLACE "lib" "" lib ${lib})
|
||||
@@ -1176,30 +1172,30 @@ macro(build_example name source_files header_files libraries_to_link)
|
||||
|
||||
if(NOT ${missing_dependencies})
|
||||
# Create shared library with sources and headers
|
||||
add_executable(${name} "${source_files}" "${header_files}")
|
||||
add_executable(${EXAMPLE_NAME} "${EXAMPLE_SOURCE_FILES}" "${EXAMPLE_HEADER_FILES}")
|
||||
|
||||
if(${NS3_STATIC})
|
||||
target_link_libraries(
|
||||
${name} ${LIB_AS_NEEDED_PRE_STATIC} ${lib-ns3-static}
|
||||
${EXAMPLE_NAME} ${LIB_AS_NEEDED_PRE_STATIC} ${lib-ns3-static}
|
||||
)
|
||||
elseif(${NS3_MONOLIB})
|
||||
target_link_libraries(
|
||||
${name} ${LIB_AS_NEEDED_PRE} ${lib-ns3-monolib} ${LIB_AS_NEEDED_POST}
|
||||
${EXAMPLE_NAME} ${LIB_AS_NEEDED_PRE} ${lib-ns3-monolib} ${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
else()
|
||||
# Link the shared library with the libraries passed
|
||||
target_link_libraries(
|
||||
${name} ${LIB_AS_NEEDED_PRE} ${libraries_to_link}
|
||||
${EXAMPLE_NAME} ${LIB_AS_NEEDED_PRE} ${EXAMPLE_LIBRARIES_TO_LINK}
|
||||
${optional_visualizer_lib} ${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${PRECOMPILE_HEADERS_ENABLED})
|
||||
target_precompile_headers(${name} REUSE_FROM stdlib_pch_exec)
|
||||
target_precompile_headers(${EXAMPLE_NAME} REUSE_FROM stdlib_pch_exec)
|
||||
endif()
|
||||
|
||||
set_runtime_outputdirectory(
|
||||
${name} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/examples/${examplefolder}/ ""
|
||||
${EXAMPLE_NAME} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/examples/${examplefolder}/ ""
|
||||
)
|
||||
endif()
|
||||
endmacro()
|
||||
@@ -1458,7 +1454,8 @@ function(find_external_library_header_and_library name header_name library_name
|
||||
)
|
||||
mark_as_advanced(${name}_library)
|
||||
find_library(
|
||||
${name}_library ${library_name} HINTS ${search_paths} ENV LD_LIBRARY_PATH
|
||||
${name}_library ${library_name}
|
||||
HINTS ${search_paths} ENV LD_LIBRARY_PATH
|
||||
PATH_SUFFIXES /build /lib /build/lib /
|
||||
)
|
||||
set(${name}_library_dir)
|
||||
@@ -1532,7 +1529,8 @@ function(check_python_packages packages missing_packages)
|
||||
foreach(package ${packages})
|
||||
execute_process(
|
||||
COMMAND ${Python_EXECUTABLE} -c "import ${package}"
|
||||
RESULT_VARIABLE return_code OUTPUT_QUIET ERROR_QUIET
|
||||
RESULT_VARIABLE return_code
|
||||
OUTPUT_QUIET ERROR_QUIET
|
||||
)
|
||||
if(NOT (${return_code} EQUAL 0))
|
||||
list(APPEND missing ${package})
|
||||
|
||||
@@ -105,6 +105,12 @@ A ns-3 module is created as a cpp/shlib object, like this:
|
||||
test/test-mymodule.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}" "${test_sources}")
|
||||
build_lib(
|
||||
LIBNAME ${name}
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK ${libraries_to_link}
|
||||
TEST_SOURCES ${test_sources}
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -5,7 +5,8 @@ if(${ENABLE_EXAMPLES})
|
||||
foreach(examplefolder ${examples_to_build})
|
||||
add_subdirectory(${examplefolder})
|
||||
|
||||
set(ns3-example-folders "${examplefolder};${ns3-example-folders}"
|
||||
set(ns3-example-folders
|
||||
"${examplefolder};${ns3-example-folders}"
|
||||
CACHE INTERNAL "list of example folders"
|
||||
)
|
||||
endforeach()
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
set(name three-gpp-v2v-channel-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libpropagation}
|
||||
${libspectrum} ${libantenna} ${libbuildings}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME three-gpp-v2v-channel-example
|
||||
SOURCE_FILES three-gpp-v2v-channel-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libpropagation}
|
||||
${libspectrum}
|
||||
${libantenna}
|
||||
${libbuildings}
|
||||
)
|
||||
|
||||
@@ -1,19 +1,23 @@
|
||||
set(name energy-model-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libwifi} ${libenergy}
|
||||
${libinternet} ${libconfig-store}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME energy-model-example
|
||||
SOURCE_FILES energy-model-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libwifi}
|
||||
${libenergy}
|
||||
${libinternet}
|
||||
${libconfig-store}
|
||||
)
|
||||
|
||||
set(name energy-model-with-harvesting-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libwifi} ${libenergy}
|
||||
${libinternet} ${libconfig-store}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME energy-model-with-harvesting-example
|
||||
SOURCE_FILES energy-model-with-harvesting-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libwifi}
|
||||
${libenergy}
|
||||
${libinternet}
|
||||
${libconfig-store}
|
||||
)
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
set(name simple-error-model)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME simple-error-model
|
||||
SOURCE_FILES simple-error-model.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,83 +1,90 @@
|
||||
set(name fragmentation-ipv6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fragmentation-ipv6
|
||||
SOURCE_FILES fragmentation-ipv6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name fragmentation-ipv6-two-MTU)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fragmentation-ipv6-two-MTU
|
||||
SOURCE_FILES fragmentation-ipv6-two-MTU.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name icmpv6-redirect)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME icmpv6-redirect
|
||||
SOURCE_FILES icmpv6-redirect.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name loose-routing-ipv6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME loose-routing-ipv6
|
||||
SOURCE_FILES loose-routing-ipv6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name ping6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME ping6
|
||||
SOURCE_FILES ping6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name radvd)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME radvd
|
||||
SOURCE_FILES radvd.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name radvd-two-prefix)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME radvd-two-prefix
|
||||
SOURCE_FILES radvd-two-prefix.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name test-ipv6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME test-ipv6
|
||||
SOURCE_FILES test-ipv6.cc
|
||||
LIBRARIES_TO_LINK ${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name wsn-ping6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblr-wpan} ${libinternet} ${libsixlowpan}
|
||||
${libmobility} ${libinternet-apps}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wsn-ping6
|
||||
SOURCE_FILES wsn-ping6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${liblr-wpan}
|
||||
${libinternet}
|
||||
${libsixlowpan}
|
||||
${libmobility}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name fragmentation-ipv6-PMTU)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps}
|
||||
${libpoint-to-point}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fragmentation-ipv6-PMTU
|
||||
SOURCE_FILES fragmentation-ipv6-PMTU.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
${libpoint-to-point}
|
||||
)
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
set(name matrix-topology)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libnetanim} ${libmobility}
|
||||
${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME matrix-topology
|
||||
SOURCE_FILES matrix-topology.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libnetanim}
|
||||
${libmobility}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,7 +1,14 @@
|
||||
set(name object-names)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libcsma} ${libinternet} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(name
|
||||
object-names
|
||||
)
|
||||
|
||||
set(libraries_to_link)
|
||||
build_example(
|
||||
NAME object-names
|
||||
SOURCE_FILES object-names.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
if(${ENABLE_REALTIME})
|
||||
set(name realtime-udp-echo)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME realtime-udp-echo
|
||||
SOURCE_FILES realtime-udp-echo.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
endif()
|
||||
|
||||
@@ -1,83 +1,90 @@
|
||||
set(name dynamic-global-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libcsma} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME dynamic-global-routing
|
||||
SOURCE_FILES dynamic-global-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name static-routing-slash32)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libcsma} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME static-routing-slash32
|
||||
SOURCE_FILES static-routing-slash32.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name global-routing-slash32)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libcsma} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME global-routing-slash32
|
||||
SOURCE_FILES global-routing-slash32.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name global-injection-slash32)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libcsma} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME global-injection-slash32
|
||||
SOURCE_FILES global-injection-slash32.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name simple-global-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(name
|
||||
simple-global-routing
|
||||
)
|
||||
|
||||
set(name simple-alternate-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications})
|
||||
set(libraries_to_link)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME simple-global-routing
|
||||
SOURCE_FILES simple-global-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name mixed-global-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libcsma}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME simple-alternate-routing
|
||||
SOURCE_FILES simple-alternate-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name simple-routing-ping6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME mixed-global-routing
|
||||
SOURCE_FILES mixed-global-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libcsma}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name manet-routing-compare)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
build_example(
|
||||
NAME simple-routing-ping6
|
||||
SOURCE_FILES simple-routing-ping6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
build_example(
|
||||
NAME manet-routing-compare
|
||||
SOURCE_FILES manet-routing-compare.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libdsr}
|
||||
${libdsdv}
|
||||
@@ -86,30 +93,29 @@ set(libraries_to_link
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME ripng-simple-network
|
||||
SOURCE_FILES ripng-simple-network.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name ripng-simple-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME rip-simple-network
|
||||
SOURCE_FILES rip-simple-network.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name rip-simple-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libinternet-apps})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name global-routing-multi-switch-plus-router)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
NAME global-routing-multi-switch-plus-router
|
||||
SOURCE_FILES global-routing-multi-switch-plus-router.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libapplications}
|
||||
@@ -120,16 +126,13 @@ set(libraries_to_link
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name simple-multicast-flooding)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libnetwork} ${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME simple-multicast-flooding
|
||||
SOURCE_FILES simple-multicast-flooding.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
@@ -1,39 +1,40 @@
|
||||
set(name socket-bound-static-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libcsma} ${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME socket-bound-static-routing
|
||||
SOURCE_FILES socket-bound-static-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name socket-bound-tcp-static-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libcsma} ${libpoint-to-point}
|
||||
${libinternet} ${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME socket-bound-tcp-static-routing
|
||||
SOURCE_FILES socket-bound-tcp-static-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name socket-options-ipv4)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libcsma} ${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME socket-options-ipv4
|
||||
SOURCE_FILES socket-options-ipv4.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name socket-options-ipv6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libcsma} ${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME socket-options-ipv6
|
||||
SOURCE_FILES socket-options-ipv6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
set(name wifi-example-sim)
|
||||
set(source_files ${name}.cc wifi-example-apps.cc)
|
||||
set(header_files wifi-example-apps.h)
|
||||
set(libraries_to_link ${libstats} ${libinternet} ${libmobility} ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-example-sim
|
||||
SOURCE_FILES wifi-example-sim.cc
|
||||
wifi-example-apps.cc
|
||||
HEADER_FILES wifi-example-apps.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libstats}
|
||||
${libinternet}
|
||||
${libmobility}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
@@ -1,30 +1,36 @@
|
||||
set(name tcp-large-transfer)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libapplications} ${libinternet})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-large-transfer
|
||||
SOURCE_FILES tcp-large-transfer.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name tcp-star-server)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libapplications} ${libinternet})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-star-server
|
||||
SOURCE_FILES tcp-star-server.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name star)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link
|
||||
${libnetanim} ${libpoint-to-point} ${libpoint-to-point-layout}
|
||||
${libapplications} ${libinternet}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME star
|
||||
SOURCE_FILES star.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetanim}
|
||||
${libpoint-to-point}
|
||||
${libpoint-to-point-layout}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name tcp-bbr-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link
|
||||
build_example(
|
||||
NAME tcp-bbr-example
|
||||
SOURCE_FILES tcp-bbr-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
@@ -33,66 +39,76 @@ set(libraries_to_link
|
||||
${libinternet-apps}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-bulk-send
|
||||
SOURCE_FILES tcp-bulk-send.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name tcp-bulk-send)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libapplications} ${libinternet})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-pcap-nanosec-example
|
||||
SOURCE_FILES tcp-pcap-nanosec-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name tcp-pcap-nanosec-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libapplications} ${libinternet})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-variants-comparison
|
||||
SOURCE_FILES tcp-variants-comparison.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name tcp-variants-comparison)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-pacing
|
||||
SOURCE_FILES tcp-pacing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name tcp-pacing)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-linux-reno
|
||||
SOURCE_FILES tcp-linux-reno.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
${libnetwork}
|
||||
)
|
||||
|
||||
set(name tcp-linux-reno)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libtraffic-control} ${libnetwork}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tcp-validation
|
||||
SOURCE_FILES tcp-validation.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
${libnetwork}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name tcp-validation)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libtraffic-control} ${libnetwork} ${libinternet-apps}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name dctcp-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link
|
||||
${libcore} ${libnetwork} ${libinternet} ${libpoint-to-point}
|
||||
${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME dctcp-example
|
||||
SOURCE_FILES dctcp-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
@@ -1,62 +1,64 @@
|
||||
set(name traffic-control)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libpoint-to-point} ${libapplications}
|
||||
${libtraffic-control} ${libflow-monitor}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME traffic-control
|
||||
SOURCE_FILES traffic-control.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name queue-discs-benchmark)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
${libinternet} ${libpoint-to-point} ${libapplications} ${libinternet-apps}
|
||||
${libtraffic-control} ${libflow-monitor}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME queue-discs-benchmark
|
||||
SOURCE_FILES queue-discs-benchmark.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet-apps}
|
||||
${libtraffic-control}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name red-vs-fengadaptive)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
${libinternet} ${libpoint-to-point} ${libpoint-to-point-layout}
|
||||
${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME red-vs-fengadaptive
|
||||
SOURCE_FILES red-vs-fengadaptive.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libpoint-to-point-layout}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name red-vs-nlred)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
${libinternet} ${libpoint-to-point} ${libpoint-to-point-layout}
|
||||
${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME red-vs-nlred
|
||||
SOURCE_FILES red-vs-nlred.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libpoint-to-point-layout}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name tbf-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libpoint-to-point} ${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tbf-example
|
||||
SOURCE_FILES tbf-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name cobalt-vs-codel)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libpoint-to-point} ${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME cobalt-vs-codel
|
||||
SOURCE_FILES cobalt-vs-codel.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
@@ -1,75 +1,75 @@
|
||||
set(name hello-simulator)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME hello-simulator
|
||||
SOURCE_FILES hello-simulator.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
)
|
||||
|
||||
set(name first)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpoint-to-point} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME first
|
||||
SOURCE_FILES first.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name second)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpoint-to-point} ${libcsma} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME second
|
||||
SOURCE_FILES second.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpoint-to-point}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name third)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpoint-to-point} ${libcsma} ${libwifi}
|
||||
${libinternet} ${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME third
|
||||
SOURCE_FILES third.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpoint-to-point}
|
||||
${libcsma}
|
||||
${libwifi}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name fourth)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fourth
|
||||
SOURCE_FILES fourth.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
)
|
||||
|
||||
set(name fifth)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpoint-to-point} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fifth
|
||||
SOURCE_FILES fifth.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name sixth)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpoint-to-point} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME sixth
|
||||
SOURCE_FILES sixth.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name seventh)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libstats} ${libpoint-to-point}
|
||||
${libinternet} ${libapplications}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME seventh
|
||||
SOURCE_FILES seventh.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libstats}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,15 +1,17 @@
|
||||
set(name udp-client-server)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME udp-client-server
|
||||
SOURCE_FILES udp-client-server.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name udp-trace-client-server)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME udp-trace-client-server
|
||||
SOURCE_FILES udp-trace-client-server.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
set(name udp-echo)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME udp-echo
|
||||
SOURCE_FILES udp-echo.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,315 +1,287 @@
|
||||
set(name mixed-wired-wireless)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications} ${libolsr} ${libnetanim})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME mixed-wired-wireless
|
||||
SOURCE_FILES mixed-wired-wireless.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libapplications}
|
||||
${libolsr}
|
||||
${libnetanim}
|
||||
)
|
||||
|
||||
set(name wifi-80211e-txop)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-80211e-txop
|
||||
SOURCE_FILES wifi-80211e-txop.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-80211n-mimo)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-80211n-mimo
|
||||
SOURCE_FILES wifi-80211n-mimo.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-adhoc)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-adhoc
|
||||
SOURCE_FILES wifi-adhoc.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-aggregation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-aggregation
|
||||
SOURCE_FILES wifi-aggregation.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-ap)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-ap
|
||||
SOURCE_FILES wifi-ap.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-backward-compatibility)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-backward-compatibility
|
||||
SOURCE_FILES wifi-backward-compatibility.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-blockack)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-blockack
|
||||
SOURCE_FILES wifi-blockack.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-clear-channel-cmu)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-clear-channel-cmu
|
||||
SOURCE_FILES wifi-clear-channel-cmu.cc
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-dsss-validation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-dsss-validation
|
||||
SOURCE_FILES wifi-dsss-validation.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-he-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-he-network
|
||||
SOURCE_FILES wifi-he-network.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-hidden-terminal)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications} ${libflow-monitor})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-hidden-terminal
|
||||
SOURCE_FILES wifi-hidden-terminal.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name wifi-ht-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-ht-network
|
||||
SOURCE_FILES wifi-ht-network.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-mixed-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-mixed-network
|
||||
SOURCE_FILES wifi-mixed-network.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-multi-tos)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-multi-tos
|
||||
SOURCE_FILES wifi-multi-tos.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-multirate)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libwifi} ${libolsr} ${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-multirate
|
||||
SOURCE_FILES wifi-multirate.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libwifi}
|
||||
${libolsr}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name wifi-ofdm-he-validation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-ofdm-he-validation
|
||||
SOURCE_FILES wifi-ofdm-he-validation.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-ofdm-ht-validation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-ofdm-ht-validation
|
||||
SOURCE_FILES wifi-ofdm-ht-validation.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-ofdm-validation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-ofdm-validation
|
||||
SOURCE_FILES wifi-ofdm-validation.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-ofdm-vht-validation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libwifi} ${libconfig-store}
|
||||
${libstats}
|
||||
)
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-ofdm-vht-validation
|
||||
SOURCE_FILES wifi-ofdm-vht-validation.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libwifi}
|
||||
${libconfig-store}
|
||||
${libstats}
|
||||
)
|
||||
|
||||
set(name wifi-error-models-comparison)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-error-models-comparison
|
||||
SOURCE_FILES wifi-error-models-comparison.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-power-adaptation-distance)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-power-adaptation-distance
|
||||
SOURCE_FILES wifi-power-adaptation-distance.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-power-adaptation-interference)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications} ${libflow-monitor})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-power-adaptation-interference
|
||||
SOURCE_FILES wifi-power-adaptation-interference.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
set(name wifi-rate-adaptation-distance)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-rate-adaptation-distance
|
||||
SOURCE_FILES wifi-rate-adaptation-distance.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-simple-adhoc)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-simple-adhoc
|
||||
SOURCE_FILES wifi-simple-adhoc.cc
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-simple-adhoc-grid)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libwifi} ${libolsr})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-simple-adhoc-grid
|
||||
SOURCE_FILES wifi-simple-adhoc-grid.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libwifi}
|
||||
${libolsr}
|
||||
)
|
||||
|
||||
set(name wifi-simple-ht-hidden-stations)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-simple-ht-hidden-stations
|
||||
SOURCE_FILES wifi-simple-ht-hidden-stations.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-simple-infra)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-simple-infra
|
||||
SOURCE_FILES wifi-simple-infra.cc
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-simple-interference)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libwifi})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-simple-interference
|
||||
SOURCE_FILES wifi-simple-interference.cc
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
set(name wifi-sleep)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-sleep
|
||||
SOURCE_FILES wifi-sleep.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-spatial-reuse)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-spatial-reuse
|
||||
SOURCE_FILES wifi-spatial-reuse.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-spectrum-per-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-spectrum-per-example
|
||||
SOURCE_FILES wifi-spectrum-per-example.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-spectrum-per-interference)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-spectrum-per-interference
|
||||
SOURCE_FILES wifi-spectrum-per-interference.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-spectrum-saturation-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-spectrum-saturation-example
|
||||
SOURCE_FILES wifi-spectrum-saturation-example.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-tcp)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-tcp
|
||||
SOURCE_FILES wifi-tcp.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-timing-attributes)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-timing-attributes
|
||||
SOURCE_FILES wifi-timing-attributes.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-txop-aggregation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-txop-aggregation
|
||||
SOURCE_FILES wifi-txop-aggregation.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-vht-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-vht-network
|
||||
SOURCE_FILES wifi-vht-network.cc
|
||||
LIBRARIES_TO_LINK ${libwifi}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name wifi-wired-bridging)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libcsma} ${libbridge} ${libapplications})
|
||||
build_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME wifi-wired-bridging
|
||||
SOURCE_FILES wifi-wired-bridging.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libcsma}
|
||||
${libbridge}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -68,8 +68,10 @@ endforeach()
|
||||
|
||||
# Scan *.cc files in ns-3-dev/scratch subdirectories and build a target for each
|
||||
# subdirectory
|
||||
file(GLOB_RECURSE scratch_subdirectories LIST_DIRECTORIES true
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/**
|
||||
file(
|
||||
GLOB_RECURSE scratch_subdirectories
|
||||
LIST_DIRECTORIES true
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/**
|
||||
)
|
||||
# Filter out files
|
||||
foreach(entry ${scratch_subdirectories})
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name antenna)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME antenna
|
||||
SOURCE_FILES
|
||||
model/angles.cc
|
||||
model/antenna-model.cc
|
||||
model/cosine-antenna-model.cc
|
||||
@@ -9,9 +9,7 @@ set(source_files
|
||||
model/phased-array-model.cc
|
||||
model/three-gpp-antenna-model.cc
|
||||
model/uniform-planar-array.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
model/angles.h
|
||||
model/antenna-model.h
|
||||
model/cosine-antenna-model.h
|
||||
@@ -20,17 +18,12 @@ set(header_files
|
||||
model/phased-array-model.h
|
||||
model/three-gpp-antenna-model.h
|
||||
model/uniform-planar-array.h
|
||||
)
|
||||
|
||||
# link to dependencies
|
||||
set(libraries_to_link ${libcore})
|
||||
|
||||
set(test_sources
|
||||
test/test-angles.cc test/test-degrees-radians.cc
|
||||
test/test-isotropic-antenna.cc test/test-cosine-antenna.cc
|
||||
test/test-parabolic-antenna.cc test/test-uniform-planar-array.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
TEST_SOURCES
|
||||
test/test-angles.cc
|
||||
test/test-degrees-radians.cc
|
||||
test/test-isotropic-antenna.cc
|
||||
test/test-cosine-antenna.cc
|
||||
test/test-parabolic-antenna.cc
|
||||
test/test-uniform-planar-array.cc
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name aodv)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME aodv
|
||||
SOURCE_FILES
|
||||
helper/aodv-helper.cc
|
||||
model/aodv-dpd.cc
|
||||
model/aodv-id-cache.cc
|
||||
@@ -9,9 +9,7 @@ set(source_files
|
||||
model/aodv-routing-protocol.cc
|
||||
model/aodv-rqueue.cc
|
||||
model/aodv-rtable.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/aodv-helper.h
|
||||
model/aodv-dpd.h
|
||||
model/aodv-id-cache.h
|
||||
@@ -20,15 +18,12 @@ set(header_files
|
||||
model/aodv-routing-protocol.h
|
||||
model/aodv-rqueue.h
|
||||
model/aodv-rtable.h
|
||||
)
|
||||
|
||||
# link to dependencies
|
||||
set(libraries_to_link ${libinternet} ${libwifi})
|
||||
|
||||
set(test_sources test/aodv-id-cache-test-suite.cc test/aodv-regression.cc
|
||||
test/aodv-test-suite.cc test/loopback.cc test/bug-772.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libwifi}
|
||||
TEST_SOURCES
|
||||
test/aodv-id-cache-test-suite.cc
|
||||
test/aodv-regression.cc
|
||||
test/aodv-test-suite.cc
|
||||
test/loopback.cc
|
||||
test/bug-772.cc
|
||||
)
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
set(name aodv)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libinternet} ${libaodv} ${libinternet-apps})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME aodv
|
||||
SOURCE_FILES aodv.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libinternet}
|
||||
${libaodv}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name applications)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME applications
|
||||
SOURCE_FILES
|
||||
helper/bulk-send-helper.cc
|
||||
helper/on-off-helper.cc
|
||||
helper/packet-sink-helper.cc
|
||||
@@ -24,9 +24,7 @@ set(source_files
|
||||
model/udp-echo-server.cc
|
||||
model/udp-server.cc
|
||||
model/udp-trace-client.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/bulk-send-helper.h
|
||||
helper/on-off-helper.h
|
||||
helper/packet-sink-helper.h
|
||||
@@ -50,16 +48,10 @@ set(header_files
|
||||
model/udp-echo-server.h
|
||||
model/udp-server.h
|
||||
model/udp-trace-client.h
|
||||
)
|
||||
|
||||
# link to dependencies
|
||||
set(libraries_to_link ${libinternet} ${libstats})
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libstats}
|
||||
TEST_SOURCES
|
||||
test/three-gpp-http-client-server-test.cc
|
||||
test/bulk-send-application-test-suite.cc test/udp-client-server-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
test/bulk-send-application-test-suite.cc
|
||||
test/udp-client-server-test.cc
|
||||
)
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
set(name three-gpp-http-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libapplications} ${libpoint-to-point} ${libinternet}
|
||||
${libnetwork}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME three-gpp-http-example
|
||||
SOURCE_FILES three-gpp-http-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libapplications}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libnetwork}
|
||||
)
|
||||
|
||||
@@ -1,18 +1,13 @@
|
||||
set(name bridge)
|
||||
|
||||
set(source_files helper/bridge-helper.cc model/bridge-channel.cc
|
||||
model/bridge-net-device.cc
|
||||
)
|
||||
|
||||
set(header_files helper/bridge-helper.h model/bridge-channel.h
|
||||
model/bridge-net-device.h
|
||||
)
|
||||
|
||||
# link to dependencies
|
||||
set(libraries_to_link ${libnetwork})
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME bridge
|
||||
SOURCE_FILES
|
||||
helper/bridge-helper.cc
|
||||
model/bridge-channel.cc
|
||||
model/bridge-net-device.cc
|
||||
HEADER_FILES
|
||||
helper/bridge-helper.h
|
||||
model/bridge-channel.h
|
||||
model/bridge-net-device.h
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
TEST_SOURCES ${test_sources}
|
||||
)
|
||||
|
||||
@@ -1,15 +1,19 @@
|
||||
set(name csma-bridge)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libbridge} ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME csma-bridge
|
||||
SOURCE_FILES csma-bridge.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libbridge}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name csma-bridge-one-hop)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libbridge} ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME csma-bridge-one-hop
|
||||
SOURCE_FILES csma-bridge-one-hop.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libbridge}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,31 +1,45 @@
|
||||
set(NS3_WITH_BRITE "" CACHE PATH "Build with brite support")
|
||||
set(NS3_BRITE "OFF" CACHE INTERNAL "ON if Brite is found in NS3_WITH_BRITE")
|
||||
set(NS3_WITH_BRITE
|
||||
""
|
||||
CACHE PATH
|
||||
"Build with brite support"
|
||||
)
|
||||
set(NS3_BRITE
|
||||
"OFF"
|
||||
CACHE INTERNAL
|
||||
"ON if Brite is found in NS3_WITH_BRITE"
|
||||
)
|
||||
|
||||
find_external_library_header_and_library(
|
||||
"brite" "Brite.h" "brite" "${NS3_WITH_BRITE}"
|
||||
"brite"
|
||||
"Brite.h"
|
||||
"brite"
|
||||
"${NS3_WITH_BRITE}"
|
||||
)
|
||||
if(NOT
|
||||
(brite_library
|
||||
AND brite_header)
|
||||
)
|
||||
if(NOT (brite_library AND brite_header))
|
||||
message(STATUS "Brite was not found")
|
||||
return()
|
||||
endif()
|
||||
|
||||
# Only process module if include folder and library have been found
|
||||
include_directories(${brite_include_directories})
|
||||
set(NS3_BRITE "ON" CACHE INTERNAL "ON if Brite is found in NS3_WITH_BRITE")
|
||||
|
||||
set(name brite)
|
||||
|
||||
set(source_files helper/brite-topology-helper.cc)
|
||||
|
||||
set(header_files helper/brite-topology-helper.h)
|
||||
|
||||
# link to dependencies
|
||||
set(libraries_to_link ${libnetwork} ${libcore} ${libinternet}
|
||||
${libpoint-to-point} ${brite_library}
|
||||
set(NS3_BRITE
|
||||
"ON"
|
||||
CACHE INTERNAL
|
||||
"ON if Brite is found in NS3_WITH_BRITE"
|
||||
)
|
||||
|
||||
set(test_sources test/brite-test-topology.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME brite
|
||||
SOURCE_FILES helper/brite-topology-helper.cc
|
||||
HEADER_FILES helper/brite-topology-helper.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcore}
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${brite_library}
|
||||
TEST_SOURCES test/brite-test-topology.cc
|
||||
)
|
||||
|
||||
@@ -1,18 +1,19 @@
|
||||
set(name brite-generic-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libbrite} ${libinternet} ${libpoint-to-point}
|
||||
${libnix-vector-routing} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME brite-generic-example
|
||||
SOURCE_FILES brite-generic-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libbrite}
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libnix-vector-routing}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
if(${ENABLE_MPI})
|
||||
set(name brite-MPI-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
build_lib_example(
|
||||
NAME brite-MPI-example
|
||||
SOURCE_FILES brite-MPI-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libbrite}
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
@@ -21,8 +22,8 @@ if(${ENABLE_MPI})
|
||||
${libmpi}
|
||||
${MPI_CXX_LIBRARIES}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
target_include_directories(
|
||||
${name}
|
||||
PUBLIC ${MPI_CXX_INCLUDE_DIRS}
|
||||
)
|
||||
target_include_directories(${name} PUBLIC ${MPI_CXX_INCLUDE_DIRS})
|
||||
endif()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name buildings)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME buildings
|
||||
SOURCE_FILES
|
||||
helper/building-allocator.cc
|
||||
helper/building-container.cc
|
||||
helper/building-position-allocator.cc
|
||||
@@ -15,9 +15,7 @@ set(source_files
|
||||
model/oh-buildings-propagation-loss-model.cc
|
||||
model/random-walk-2d-outdoor-mobility-model.cc
|
||||
model/three-gpp-v2v-channel-condition-model.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/building-allocator.h
|
||||
helper/building-container.h
|
||||
helper/building-position-allocator.h
|
||||
@@ -32,11 +30,11 @@ set(header_files
|
||||
model/oh-buildings-propagation-loss-model.h
|
||||
model/random-walk-2d-outdoor-mobility-model.h
|
||||
model/three-gpp-v2v-channel-condition-model.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libmobility} ${libpropagation} ${libconfig-store})
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK
|
||||
${libmobility}
|
||||
${libpropagation}
|
||||
${libconfig-store}
|
||||
TEST_SOURCES
|
||||
test/building-position-allocator-test.cc
|
||||
test/buildings-helper-test.cc
|
||||
test/buildings-pathloss-test.cc
|
||||
@@ -45,7 +43,3 @@ set(test_sources
|
||||
test/outdoor-random-walk-test.cc
|
||||
test/three-gpp-v2v-channel-condition-model-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,25 +1,21 @@
|
||||
set(name buildings-pathloss-profiler)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libconfig-store} ${libmobility}
|
||||
${libbuildings}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME buildings-pathloss-profiler
|
||||
SOURCE_FILES buildings-pathloss-profiler.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libconfig-store}
|
||||
${libmobility}
|
||||
${libbuildings}
|
||||
)
|
||||
|
||||
set(name outdoor-group-mobility-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libbuildings})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME outdoor-group-mobility-example
|
||||
SOURCE_FILES outdoor-group-mobility-example.cc
|
||||
LIBRARIES_TO_LINK ${libbuildings}
|
||||
)
|
||||
|
||||
set(name outdoor-random-walk-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libbuildings})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME outdoor-random-walk-example
|
||||
SOURCE_FILES outdoor-random-walk-example.cc
|
||||
LIBRARIES_TO_LINK ${libbuildings}
|
||||
)
|
||||
|
||||
@@ -1,32 +1,50 @@
|
||||
set(NS3_WITH_CLICK "" CACHE PATH "Build with click support")
|
||||
set(NS3_CLICK "OFF" CACHE INTERNAL "ON if Click is found in NS3_WITH_CLICK")
|
||||
set(NS3_WITH_CLICK
|
||||
""
|
||||
CACHE PATH
|
||||
"Build with click support"
|
||||
)
|
||||
set(NS3_CLICK
|
||||
"OFF"
|
||||
CACHE INTERNAL
|
||||
"ON if Click is found in NS3_WITH_CLICK"
|
||||
)
|
||||
|
||||
find_external_library_header_and_library(
|
||||
"click" "simclick.h" "click" "${NS3_WITH_CLICK}"
|
||||
"click"
|
||||
"simclick.h"
|
||||
"click"
|
||||
"${NS3_WITH_CLICK}"
|
||||
)
|
||||
if(NOT
|
||||
(click_library
|
||||
AND click_header)
|
||||
)
|
||||
if(NOT (click_library AND click_header))
|
||||
message(STATUS "Click was not found")
|
||||
return()
|
||||
endif()
|
||||
|
||||
include_directories(${click_include_directories})
|
||||
set(NS3_CLICK "ON" CACHE INTERNAL "ON if Click is found in NS3_WITH_CLICK")
|
||||
set(NS3_CLICK
|
||||
"ON"
|
||||
CACHE INTERNAL
|
||||
"ON if Click is found in NS3_WITH_CLICK"
|
||||
)
|
||||
add_definitions(-DNS3_CLICK)
|
||||
|
||||
set(name click)
|
||||
|
||||
set(source_files helper/click-internet-stack-helper.cc
|
||||
model/ipv4-click-routing.cc model/ipv4-l3-click-protocol.cc
|
||||
)
|
||||
|
||||
set(header_files helper/click-internet-stack-helper.h
|
||||
model/ipv4-click-routing.h model/ipv4-l3-click-protocol.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libcore} ${libnetwork} ${libinternet} ${click_library})
|
||||
|
||||
set(test_sources test/ipv4-click-routing-test.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME click
|
||||
SOURCE_FILES
|
||||
helper/click-internet-stack-helper.cc
|
||||
model/ipv4-click-routing.cc
|
||||
model/ipv4-l3-click-protocol.cc
|
||||
HEADER_FILES
|
||||
helper/click-internet-stack-helper.h
|
||||
model/ipv4-click-routing.h
|
||||
model/ipv4-l3-click-protocol.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
${click_library}
|
||||
TEST_SOURCES test/ipv4-click-routing-test.cc
|
||||
)
|
||||
|
||||
@@ -1,47 +1,55 @@
|
||||
set(name nsclick-simple-lan)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libclick} ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME nsclick-simple-lan
|
||||
SOURCE_FILES nsclick-simple-lan.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libclick}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name nsclick-raw-wlan)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libclick} ${libwifi} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME nsclick-raw-wlan
|
||||
SOURCE_FILES nsclick-raw-wlan.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libclick}
|
||||
${libwifi}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name nsclick-udp-client-server-csma)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libclick} ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME nsclick-udp-client-server-csma
|
||||
SOURCE_FILES nsclick-udp-client-server-csma.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libclick}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name nsclick-udp-client-server-wifi)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libclick} ${libwifi} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME nsclick-udp-client-server-wifi
|
||||
SOURCE_FILES nsclick-udp-client-server-wifi.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libclick}
|
||||
${libwifi}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name nsclick-routing)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libclick} ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME nsclick-routing
|
||||
SOURCE_FILES nsclick-routing.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libclick}
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name nsclick-defines)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libclick})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME nsclick-defines
|
||||
SOURCE_FILES nsclick-defines.cc
|
||||
LIBRARIES_TO_LINK ${libclick}
|
||||
)
|
||||
|
||||
@@ -1,25 +1,39 @@
|
||||
set(name config-store)
|
||||
|
||||
if(${GTK3_FOUND})
|
||||
set(gtk3_sources model/display-functions.cc model/gtk-config-store.cc
|
||||
model/model-node-creator.cc model/model-typeid-creator.cc
|
||||
set(gtk3_sources
|
||||
model/display-functions.cc
|
||||
model/gtk-config-store.cc
|
||||
model/model-node-creator.cc
|
||||
model/model-typeid-creator.cc
|
||||
)
|
||||
|
||||
set(gtk3_headers model/gtk-config-store.h)
|
||||
include_directories(${GTK3_INCLUDE_DIRS} ${HarfBuzz_INCLUDE_DIRS})
|
||||
set(gtk_libraries ${GTK3_LIBRARIES})
|
||||
set(gtk3_headers
|
||||
model/gtk-config-store.h
|
||||
)
|
||||
include_directories(
|
||||
${GTK3_INCLUDE_DIRS}
|
||||
${HarfBuzz_INCLUDE_DIRS}
|
||||
)
|
||||
set(gtk_libraries
|
||||
${GTK3_LIBRARIES}
|
||||
)
|
||||
if(${GCC})
|
||||
add_definitions(-Wno-parentheses)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(${LIBXML2_FOUND})
|
||||
set(xml2_sources model/xml-config.cc)
|
||||
set(xml2_libraries ${LIBXML2_LIBRARIES})
|
||||
set(xml2_sources
|
||||
model/xml-config.cc
|
||||
)
|
||||
set(xml2_libraries
|
||||
${LIBXML2_LIBRARIES}
|
||||
)
|
||||
include_directories(${LIBXML2_INCLUDE_DIR})
|
||||
endif()
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME config-store
|
||||
SOURCE_FILES
|
||||
${gtk3_sources}
|
||||
${xml2_sources}
|
||||
model/attribute-default-iterator.cc
|
||||
@@ -27,16 +41,13 @@ set(source_files
|
||||
model/config-store.cc
|
||||
model/file-config.cc
|
||||
model/raw-text-config.cc
|
||||
)
|
||||
|
||||
set(header_files ${gtk3_headers} model/file-config.h model/config-store.h)
|
||||
|
||||
set(libraries_to_link ${libcore} ${libnetwork} ${xml2_libraries}
|
||||
${gtk_libraries}
|
||||
)
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
HEADER_FILES
|
||||
${gtk3_headers}
|
||||
model/file-config.h
|
||||
model/config-store.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${xml2_libraries}
|
||||
${gtk_libraries}
|
||||
)
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
set(name config-store-save)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libconfig-store})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME config-store-save
|
||||
SOURCE_FILES config-store-save.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
${libconfig-store}
|
||||
)
|
||||
|
||||
@@ -1,23 +1,35 @@
|
||||
# Set module name
|
||||
set(name core)
|
||||
|
||||
# Set lib core link dependencies
|
||||
set(libraries_to_link)
|
||||
|
||||
set(gsl_test_sources)
|
||||
if(${GSL_FOUND})
|
||||
include_directories(${GSL_INCLUDE_DIRS})
|
||||
set(libraries_to_link ${libraries_to_link} ${GSL_LIBRARIES})
|
||||
set(gsl_test_sources test/rng-test-suite.cc
|
||||
test/random-variable-stream-test-suite.cc
|
||||
set(libraries_to_link
|
||||
${libraries_to_link}
|
||||
${GSL_LIBRARIES}
|
||||
)
|
||||
set(gsl_test_sources
|
||||
test/rng-test-suite.cc
|
||||
test/random-variable-stream-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
|
||||
# Check for dependencies and add sources accordingly
|
||||
check_include_file_cxx("boost/units/quantity.hpp" HAVE_BOOST_UNITS_QUANTITY)
|
||||
check_include_file_cxx("boost/units/systems/si.hpp" HAVE_BOOST_UNITS_SI)
|
||||
if(${HAVE_BOOST_UNITS_QUANTITY} AND ${HAVE_BOOST_UNITS_SI})
|
||||
add_definitions(-DHAVE_BOOST -DHAVE_BOOST_UNITS)
|
||||
check_include_file_cxx(
|
||||
"boost/units/quantity.hpp"
|
||||
HAVE_BOOST_UNITS_QUANTITY
|
||||
)
|
||||
check_include_file_cxx(
|
||||
"boost/units/systems/si.hpp"
|
||||
HAVE_BOOST_UNITS_SI
|
||||
)
|
||||
if(${HAVE_BOOST_UNITS_QUANTITY}
|
||||
AND ${HAVE_BOOST_UNITS_SI}
|
||||
)
|
||||
add_definitions(
|
||||
-DHAVE_BOOST
|
||||
-DHAVE_BOOST_UNITS
|
||||
)
|
||||
message(STATUS "Boost Units have been found.")
|
||||
else()
|
||||
message(
|
||||
@@ -28,28 +40,59 @@ else()
|
||||
)
|
||||
endif()
|
||||
|
||||
set(rt_sources model/realtime-simulator-impl.cc
|
||||
model/wall-clock-synchronizer.cc
|
||||
set(rt_sources
|
||||
model/realtime-simulator-impl.cc
|
||||
model/wall-clock-synchronizer.cc
|
||||
)
|
||||
set(rt_headers
|
||||
model/realtime-simulator-impl.h
|
||||
model/wall-clock-synchronizer.h
|
||||
)
|
||||
set(rt_headers model/realtime-simulator-impl.h model/wall-clock-synchronizer.h)
|
||||
if(${ENABLE_REALTIME})
|
||||
set(libraries_to_link ${libraries_to_link} ${LIBRT})
|
||||
set(libraries_to_link
|
||||
${libraries_to_link}
|
||||
${LIBRT}
|
||||
)
|
||||
endif()
|
||||
|
||||
set(osclock_sources)
|
||||
set(osclock_sources model/unix-system-wall-clock-ms.cc)
|
||||
set(osclock_sources
|
||||
model/unix-system-wall-clock-ms.cc
|
||||
)
|
||||
|
||||
set(int64x64_sources)
|
||||
set(int64x64_headers)
|
||||
|
||||
if(${NS3_INT64X64} MATCHES "INT128")
|
||||
set(int64x64_sources model/int64x64-128.cc)
|
||||
set(int64x64_headers model/int64x64-128.h)
|
||||
elseif(${NS3_INT64X64} MATCHES "DOUBLE")
|
||||
set(int64x64_headers model/int64x64-double.h)
|
||||
elseif(${NS3_INT64X64} MATCHES "CAIRO")
|
||||
set(int64x64_sources model/int64x64-cairo.cc)
|
||||
set(int64x64_headers model/int64x64-cairo.h model/cairo-wideint-private.h)
|
||||
if(${NS3_INT64X64}
|
||||
MATCHES
|
||||
"INT128"
|
||||
)
|
||||
set(int64x64_sources
|
||||
model/int64x64-128.cc
|
||||
)
|
||||
set(int64x64_headers
|
||||
model/int64x64-128.h
|
||||
)
|
||||
elseif(
|
||||
${NS3_INT64X64}
|
||||
MATCHES
|
||||
"DOUBLE"
|
||||
)
|
||||
set(int64x64_headers
|
||||
model/int64x64-double.h
|
||||
)
|
||||
elseif(
|
||||
${NS3_INT64X64}
|
||||
MATCHES
|
||||
"CAIRO"
|
||||
)
|
||||
set(int64x64_sources
|
||||
model/int64x64-cairo.cc
|
||||
)
|
||||
set(int64x64_headers
|
||||
model/int64x64-cairo.h
|
||||
model/cairo-wideint-private.h
|
||||
)
|
||||
endif()
|
||||
|
||||
set(thread_sources)
|
||||
@@ -58,33 +101,57 @@ set(thread_test_sources)
|
||||
|
||||
if(${NS3_PTHREAD})
|
||||
if(${THREADS_FOUND})
|
||||
set(thread_sources model/unix-fd-reader.cc)
|
||||
set(thread_headers model/unix-fd-reader.h)
|
||||
set(thread_sources
|
||||
${thread_sources} model/system-thread.cc model/unix-system-mutex.cc
|
||||
model/unix-fd-reader.cc
|
||||
)
|
||||
set(thread_headers
|
||||
model/unix-fd-reader.h
|
||||
)
|
||||
set(thread_sources
|
||||
${thread_sources}
|
||||
model/system-thread.cc
|
||||
model/unix-system-mutex.cc
|
||||
model/unix-system-condition.cc
|
||||
)
|
||||
|
||||
set(thread_headers ${thread_headers} model/system-mutex.h
|
||||
model/system-thread.h model/system-condition.h
|
||||
set(thread_headers
|
||||
${thread_headers}
|
||||
model/system-mutex.h
|
||||
model/system-thread.h
|
||||
model/system-condition.h
|
||||
)
|
||||
set(libraries_to_link
|
||||
${libraries_to_link}
|
||||
pthread
|
||||
)
|
||||
set(thread_test_sources
|
||||
test/threaded-test-suite.cc
|
||||
)
|
||||
set(libraries_to_link ${libraries_to_link} pthread)
|
||||
set(thread_test_sources test/threaded-test-suite.cc)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(${ENABLE_EXAMPLES})
|
||||
set(example_as_test_sources model/example-as-test.cc)
|
||||
set(example_as_test_headers model/example-as-test.h)
|
||||
set(example_as_test_suite test/examples-as-tests-test-suite.cc)
|
||||
set(example_as_test_sources
|
||||
model/example-as-test.cc
|
||||
)
|
||||
set(example_as_test_headers
|
||||
model/example-as-test.h
|
||||
)
|
||||
set(example_as_test_suite
|
||||
test/examples-as-tests-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
|
||||
# Embedded version support
|
||||
set(embedded_version_sources)
|
||||
set(embedded_version_headers)
|
||||
if(${NS3_ENABLE_BUILD_VERSION})
|
||||
set(embedded_version_sources model/version.cc)
|
||||
set(embedded_version_headers model/version.h)
|
||||
set(embedded_version_sources
|
||||
model/version.cc
|
||||
)
|
||||
set(embedded_version_headers
|
||||
model/version.h
|
||||
)
|
||||
endif()
|
||||
|
||||
# Define core lib sources
|
||||
@@ -298,6 +365,10 @@ set(test_sources
|
||||
)
|
||||
|
||||
# Build core lib
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME core
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK ${libraries_to_link}
|
||||
TEST_SOURCES ${test_sources}
|
||||
)
|
||||
|
||||
@@ -1,139 +1,58 @@
|
||||
set(name main-callback)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
command-line-example
|
||||
fatal-example
|
||||
hash-example
|
||||
length-example
|
||||
main-callback
|
||||
main-ptr
|
||||
sample-log-time-format
|
||||
sample-random-variable
|
||||
sample-random-variable-stream
|
||||
sample-show-progress
|
||||
sample-simulator
|
||||
system-path-examples
|
||||
test-string-value-formatting
|
||||
)
|
||||
|
||||
set(name sample-simulator)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
set(name main-ptr)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name main-random-variable-stream)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libconfig-store} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name sample-random-variable)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name sample-random-variable-stream)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name command-line-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name fatal-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name hash-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name sample-log-time-format)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name test-string-value-formatting)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name sample-show-progress)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME main-random-variable-stream
|
||||
SOURCE_FILES main-random-variable-stream.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libconfig-store}
|
||||
${libstats}
|
||||
)
|
||||
|
||||
if(${NS3_ENABLE_BUILD_VERSION})
|
||||
set(name build-version-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME build-version-example
|
||||
SOURCE_FILES build-version-example.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${ENABLE_REALTIME})
|
||||
set(name main-test-sync)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME main-test-sync
|
||||
SOURCE_FILES main-test-sync.cc
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
)
|
||||
endif()
|
||||
|
||||
set(name length-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name empirical-random-variable-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libflow-monitor})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name system-path-examples)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME empirical-random-variable-example
|
||||
SOURCE_FILES empirical-random-variable-example.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
${libflow-monitor}
|
||||
)
|
||||
|
||||
@@ -1,15 +1,10 @@
|
||||
set(name csma-layout)
|
||||
|
||||
set(source_files model/csma-star-helper.cc)
|
||||
|
||||
set(header_files model/csma-star-helper.h)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${libinternet} ${libcsma}
|
||||
${libpoint-to-point}
|
||||
)
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME csma-layout
|
||||
SOURCE_FILES model/csma-star-helper.cc
|
||||
HEADER_FILES model/csma-star-helper.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
)
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
set(name csma-star)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libcsma-layout} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME csma-star
|
||||
SOURCE_FILES csma-star.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libcsma-layout}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,19 +1,15 @@
|
||||
set(name csma)
|
||||
|
||||
set(source_files helper/csma-helper.cc model/backoff.cc model/csma-channel.cc
|
||||
model/csma-net-device.cc
|
||||
)
|
||||
|
||||
set(header_files helper/csma-helper.h model/backoff.h model/csma-channel.h
|
||||
model/csma-net-device.h
|
||||
)
|
||||
|
||||
# Set lib csma link dependencies
|
||||
set(libraries_to_link ${libnetwork})
|
||||
|
||||
set(test_sources)
|
||||
|
||||
# Build csma lib
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME csma
|
||||
SOURCE_FILES
|
||||
helper/csma-helper.cc
|
||||
model/backoff.cc
|
||||
model/csma-channel.cc
|
||||
model/csma-net-device.cc
|
||||
HEADER_FILES
|
||||
helper/csma-helper.h
|
||||
model/backoff.h
|
||||
model/csma-channel.h
|
||||
model/csma-net-device.h
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
TEST_SOURCES ${test_sources}
|
||||
)
|
||||
|
||||
@@ -1,51 +1,39 @@
|
||||
set(name csma-one-subnet)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
set(base_examples
|
||||
csma-one-subnet
|
||||
csma-broadcast
|
||||
csma-packet-socket
|
||||
csma-multicast
|
||||
)
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME csma-raw-ip-socket
|
||||
SOURCE_FILES csma-raw-ip-socket.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name csma-broadcast)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name csma-packet-socket)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name csma-multicast)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name csma-raw-ip-socket)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications}
|
||||
${libinternet-apps}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name csma-ping)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libinternet} ${libapplications}
|
||||
${libinternet-apps}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME csma-ping
|
||||
SOURCE_FILES csma-ping.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
@@ -1,19 +1,17 @@
|
||||
set(name dsdv)
|
||||
|
||||
set(source_files
|
||||
helper/dsdv-helper.cc model/dsdv-packet-queue.cc model/dsdv-packet.cc
|
||||
model/dsdv-routing-protocol.cc model/dsdv-rtable.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
helper/dsdv-helper.h model/dsdv-packet-queue.h model/dsdv-packet.h
|
||||
model/dsdv-routing-protocol.h model/dsdv-rtable.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet})
|
||||
|
||||
set(test_sources test/dsdv-testcase.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME dsdv
|
||||
SOURCE_FILES
|
||||
helper/dsdv-helper.cc
|
||||
model/dsdv-packet-queue.cc
|
||||
model/dsdv-packet.cc
|
||||
model/dsdv-routing-protocol.cc
|
||||
model/dsdv-rtable.cc
|
||||
HEADER_FILES
|
||||
helper/dsdv-helper.h
|
||||
model/dsdv-packet-queue.h
|
||||
model/dsdv-packet.h
|
||||
model/dsdv-routing-protocol.h
|
||||
model/dsdv-rtable.h
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
TEST_SOURCES test/dsdv-testcase.cc
|
||||
)
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
set(name dsdv-manet)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libinternet} ${libdsdv} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME dsdv-manet
|
||||
SOURCE_FILES dsdv-manet.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libinternet}
|
||||
${libdsdv}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
set(name dsr)
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME dsr
|
||||
SOURCE_FILES
|
||||
helper/dsr-helper.cc
|
||||
helper/dsr-main-helper.cc
|
||||
model/dsr-errorbuff.cc
|
||||
@@ -14,9 +15,7 @@ set(source_files
|
||||
model/dsr-routing.cc
|
||||
model/dsr-rreq-table.cc
|
||||
model/dsr-rsendbuff.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/dsr-helper.h
|
||||
helper/dsr-main-helper.h
|
||||
model/dsr-errorbuff.h
|
||||
@@ -31,12 +30,7 @@ set(header_files
|
||||
model/dsr-routing.h
|
||||
model/dsr-rreq-table.h
|
||||
model/dsr-rsendbuff.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet} ${libwifi})
|
||||
|
||||
set(test_sources test/dsr-test-suite.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libwifi}
|
||||
TEST_SOURCES test/dsr-test-suite.cc
|
||||
)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
set(name dsr)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
build_lib_example(
|
||||
NAME dsr
|
||||
SOURCE_FILES dsr.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
@@ -11,6 +11,3 @@ set(libraries_to_link
|
||||
${libwifi}
|
||||
${libdsr}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name energy)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME energy
|
||||
SOURCE_FILES
|
||||
helper/basic-energy-harvester-helper.cc
|
||||
helper/basic-energy-source-helper.cc
|
||||
helper/energy-harvester-container.cc
|
||||
@@ -18,9 +18,7 @@ set(source_files
|
||||
model/li-ion-energy-source.cc
|
||||
model/rv-battery-model.cc
|
||||
model/simple-device-energy-model.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/basic-energy-harvester-helper.h
|
||||
helper/basic-energy-source-helper.h
|
||||
helper/energy-harvester-container.h
|
||||
@@ -38,14 +36,7 @@ set(header_files
|
||||
model/li-ion-energy-source.h
|
||||
model/rv-battery-model.h
|
||||
model/simple-device-energy-model.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork})
|
||||
|
||||
set(test_sources test/basic-energy-harvester-test.cc
|
||||
test/li-ion-energy-source-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
TEST_SOURCES test/basic-energy-harvester-test.cc
|
||||
test/li-ion-energy-source-test.cc
|
||||
)
|
||||
|
||||
@@ -1,23 +1,24 @@
|
||||
set(name li-ion-energy-source)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libenergy})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME li-ion-energy-source
|
||||
SOURCE_FILES li-ion-energy-source.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
${libenergy}
|
||||
)
|
||||
|
||||
set(name rv-battery-model-test)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libenergy} ${libwifi})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME rv-battery-model-test
|
||||
SOURCE_FILES rv-battery-model-test.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libenergy}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
set(name basic-energy-model-test)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libenergy} ${libwifi})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME basic-energy-model-test
|
||||
SOURCE_FILES basic-energy-model-test.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libenergy}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
@@ -1,37 +1,93 @@
|
||||
set(name fd-net-device)
|
||||
|
||||
set(module_enabled_features) # modulegen_customizations consumes this list
|
||||
|
||||
mark_as_advanced(ENABLE_THREADING)
|
||||
set(ENABLE_THREADING ${HAVE_PTHREAD_H})
|
||||
set(ENABLE_THREADING
|
||||
${HAVE_PTHREAD_H}
|
||||
)
|
||||
|
||||
check_include_file_cxx(net/ethernet.h HAVE_NET_ETHERNET_H)
|
||||
check_include_file_cxx(netpacket/packet.h HAVE_PACKET_H)
|
||||
check_include_file_cxx(net/if.h HAVE_IF_NETS_H)
|
||||
check_include_file_cxx(linux/if_tun.h HAVE_IF_TUN_H)
|
||||
check_include_file_cxx(net/netmap_user.h HAVE_NETMAP_USER_H)
|
||||
check_include_file_cxx(sys/ioctl.h HAVE_SYS_IOCTL_H)
|
||||
check_include_file_cxx(
|
||||
net/ethernet.h
|
||||
HAVE_NET_ETHERNET_H
|
||||
)
|
||||
check_include_file_cxx(
|
||||
netpacket/packet.h
|
||||
HAVE_PACKET_H
|
||||
)
|
||||
check_include_file_cxx(
|
||||
net/if.h
|
||||
HAVE_IF_NETS_H
|
||||
)
|
||||
check_include_file_cxx(
|
||||
linux/if_tun.h
|
||||
HAVE_IF_TUN_H
|
||||
)
|
||||
check_include_file_cxx(
|
||||
net/netmap_user.h
|
||||
HAVE_NETMAP_USER_H
|
||||
)
|
||||
check_include_file_cxx(
|
||||
sys/ioctl.h
|
||||
HAVE_SYS_IOCTL_H
|
||||
)
|
||||
|
||||
include(FindPkgConfig)
|
||||
if(PKG_CONFIG_FOUND)
|
||||
pkg_check_modules(DPDK libdpdk)
|
||||
pkg_check_modules(
|
||||
DPDK
|
||||
libdpdk
|
||||
)
|
||||
endif()
|
||||
|
||||
mark_as_advanced(
|
||||
ENABLE_FDNETDEV ENABLE_DPDKDEVNET ENABLE_TAPNETDEV ENABLE_EMUNETDEV
|
||||
ENABLE_FDNETDEV
|
||||
ENABLE_DPDKDEVNET
|
||||
ENABLE_TAPNETDEV
|
||||
ENABLE_EMUNETDEV
|
||||
ENABLE_NETMAP_EMU
|
||||
)
|
||||
set(ENABLE_FDNETDEV False CACHE INTERNAL "")
|
||||
set(ENABLE_DPDKDEVNET False CACHE INTERNAL "")
|
||||
set(ENABLE_TAPNETDEV False CACHE INTERNAL "")
|
||||
set(ENABLE_EMUNETDEV False CACHE INTERNAL "")
|
||||
set(ENABLE_NETMAP_EMU False CACHE INTERNAL "")
|
||||
set(ENABLE_FDNETDEV
|
||||
False
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
set(ENABLE_DPDKDEVNET
|
||||
False
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
set(ENABLE_TAPNETDEV
|
||||
False
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
set(ENABLE_EMUNETDEV
|
||||
False
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
set(ENABLE_NETMAP_EMU
|
||||
False
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
|
||||
if(${THREADS_ENABLED} AND HAVE_NET_ETHERNET_H)
|
||||
set(ENABLE_FDNETDEV True CACHE INTERNAL "")
|
||||
if(${THREADS_ENABLED}
|
||||
AND HAVE_NET_ETHERNET_H
|
||||
)
|
||||
set(ENABLE_FDNETDEV
|
||||
True
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
|
||||
if(PKG_CONFIG_FOUND AND DPDK_FOUND)
|
||||
set(ENABLE_DPDKDEVNET True CACHE INTERNAL "")
|
||||
if(PKG_CONFIG_FOUND
|
||||
AND DPDK_FOUND
|
||||
)
|
||||
set(ENABLE_DPDKDEVNET
|
||||
True
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
endif()
|
||||
|
||||
if(HAVE_IF_NETS_H
|
||||
@@ -39,7 +95,11 @@ if(${THREADS_ENABLED} AND HAVE_NET_ETHERNET_H)
|
||||
AND HAVE_SYS_IOCTL_H
|
||||
AND ${ENABLE_TAP}
|
||||
)
|
||||
set(ENABLE_TAPNETDEV True CACHE INTERNAL "")
|
||||
set(ENABLE_TAPNETDEV
|
||||
True
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
endif()
|
||||
|
||||
if(HAVE_IF_NETS_H
|
||||
@@ -47,85 +107,146 @@ if(${THREADS_ENABLED} AND HAVE_NET_ETHERNET_H)
|
||||
AND HAVE_SYS_IOCTL_H
|
||||
AND ${ENABLE_EMU}
|
||||
)
|
||||
set(ENABLE_EMUNETDEV True CACHE INTERNAL "")
|
||||
set(ENABLE_EMUNETDEV
|
||||
True
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
add_definitions(-DHAVE_PACKET_H)
|
||||
endif()
|
||||
|
||||
if(HAVE_IF_NETS_H AND HAVE_NETMAP_USER_H AND HAVE_SYS_IOCTL_H)
|
||||
set(ENABLE_NETMAP_EMU True CACHE INTERNAL "")
|
||||
if(HAVE_IF_NETS_H
|
||||
AND HAVE_NETMAP_USER_H
|
||||
AND HAVE_SYS_IOCTL_H
|
||||
)
|
||||
set(ENABLE_NETMAP_EMU
|
||||
True
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
add_definitions(-DHAVE_NETMAP_USER_H)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(${ENABLE_FDNETDEV})
|
||||
set(fd-net-device_creators)
|
||||
list(APPEND module_enabled_features FdNetDevice)
|
||||
list(
|
||||
APPEND
|
||||
module_enabled_features
|
||||
FdNetDevice
|
||||
)
|
||||
|
||||
if(${ENABLE_EMUNETDEV})
|
||||
set(emu_sources helper/emu-fd-net-device-helper.cc)
|
||||
set(emu_headers helper/emu-fd-net-device-helper.h)
|
||||
set(emu_sources
|
||||
helper/emu-fd-net-device-helper.cc
|
||||
)
|
||||
set(emu_headers
|
||||
helper/emu-fd-net-device-helper.h
|
||||
)
|
||||
|
||||
add_executable(
|
||||
raw-sock-creator helper/creator-utils.cc helper/encode-decode.cc
|
||||
helper/raw-sock-creator.cc
|
||||
raw-sock-creator
|
||||
helper/creator-utils.cc
|
||||
helper/encode-decode.cc
|
||||
helper/raw-sock-creator.cc
|
||||
)
|
||||
add_definitions(
|
||||
-DRAW_SOCK_CREATOR="${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/ns${NS3_VER}-raw-sock-creator${build_profile_suffix}"
|
||||
)
|
||||
set_runtime_outputdirectory(
|
||||
raw-sock-creator ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/ ""
|
||||
raw-sock-creator
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/
|
||||
""
|
||||
)
|
||||
|
||||
list(APPEND fd-net-device_creators raw-sock-creator)
|
||||
list(APPEND module_enabled_features EmuFdNetDevice)
|
||||
list(
|
||||
APPEND
|
||||
fd-net-device_creators
|
||||
raw-sock-creator
|
||||
)
|
||||
list(
|
||||
APPEND
|
||||
module_enabled_features
|
||||
EmuFdNetDevice
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${ENABLE_TAPNETDEV})
|
||||
set(tap_sources helper/tap-fd-net-device-helper.cc)
|
||||
set(tap_headers helper/tap-fd-net-device-helper.h)
|
||||
set(tap_sources
|
||||
helper/tap-fd-net-device-helper.cc
|
||||
)
|
||||
set(tap_headers
|
||||
helper/tap-fd-net-device-helper.h
|
||||
)
|
||||
|
||||
add_executable(
|
||||
tap-device-creator helper/creator-utils.cc helper/encode-decode.cc
|
||||
helper/tap-device-creator.cc
|
||||
tap-device-creator
|
||||
helper/creator-utils.cc
|
||||
helper/encode-decode.cc
|
||||
helper/tap-device-creator.cc
|
||||
)
|
||||
add_definitions(
|
||||
-DTAP_DEV_CREATOR="${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/ns${NS3_VER}-tap-device-creator${build_profile_suffix}"
|
||||
)
|
||||
set_runtime_outputdirectory(
|
||||
tap-device-creator ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/
|
||||
tap-device-creator
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/
|
||||
""
|
||||
)
|
||||
|
||||
list(APPEND fd-net-device_creators tap-device-creator)
|
||||
list(APPEND module_enabled_features TapFdNetDevice)
|
||||
list(
|
||||
APPEND
|
||||
fd-net-device_creators
|
||||
tap-device-creator
|
||||
)
|
||||
list(
|
||||
APPEND
|
||||
module_enabled_features
|
||||
TapFdNetDevice
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${ENABLE_NETMAP_EMU})
|
||||
set(netmap_sources helper/netmap-net-device-helper.cc
|
||||
model/netmap-net-device.cc
|
||||
set(netmap_sources
|
||||
helper/netmap-net-device-helper.cc
|
||||
model/netmap-net-device.cc
|
||||
)
|
||||
set(netmap_headers helper/netmap-net-device-helper.h
|
||||
model/netmap-net-device.h
|
||||
set(netmap_headers
|
||||
helper/netmap-net-device-helper.h
|
||||
model/netmap-net-device.h
|
||||
)
|
||||
|
||||
add_executable(
|
||||
netmap-device-creator helper/creator-utils.cc helper/encode-decode.cc
|
||||
helper/netmap-device-creator.cc
|
||||
netmap-device-creator
|
||||
helper/creator-utils.cc
|
||||
helper/encode-decode.cc
|
||||
helper/netmap-device-creator.cc
|
||||
)
|
||||
add_definitions(
|
||||
-DNETMAP_DEV_CREATOR="${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/ns${NS3_VER}-netmap-device-creator${build_profile_suffix}"
|
||||
)
|
||||
set_runtime_outputdirectory(
|
||||
netmap-device-creator
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/ ""
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/fd-net-device/
|
||||
""
|
||||
)
|
||||
|
||||
list(APPEND fd-net-device_creators netmap-device-creator)
|
||||
list(
|
||||
APPEND
|
||||
fd-net-device_creators
|
||||
netmap-device-creator
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${ENABLE_DPDKDEVNET})
|
||||
set(dpdk_sources model/dpdk-net-device.cc helper/dpdk-net-device-helper.cc)
|
||||
set(dpdk_headers model/dpdk-net-device.h helper/dpdk-net-device-helper.h)
|
||||
set(dpdk_sources
|
||||
model/dpdk-net-device.cc
|
||||
helper/dpdk-net-device-helper.cc
|
||||
)
|
||||
set(dpdk_headers
|
||||
model/dpdk-net-device.h
|
||||
helper/dpdk-net-device-helper.h
|
||||
)
|
||||
add_definitions(-DHAVE_DPDK_USER_H)
|
||||
endif()
|
||||
|
||||
@@ -140,29 +261,55 @@ if(${ENABLE_FDNETDEV})
|
||||
model/fd-net-device.cc
|
||||
)
|
||||
|
||||
set(header_files ${tap_headers} ${emu_headers} ${dpdk_headers}
|
||||
model/fd-net-device.h helper/fd-net-device-helper.h
|
||||
set(header_files
|
||||
${tap_headers}
|
||||
${emu_headers}
|
||||
${dpdk_headers}
|
||||
model/fd-net-device.h
|
||||
helper/fd-net-device-helper.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${LIB_AS_NEEDED_PRE} ${DPDK_LIBRARIES}
|
||||
${LIB_AS_NEEDED_POST}
|
||||
set(libraries_to_link
|
||||
${libnetwork}
|
||||
${LIB_AS_NEEDED_PRE}
|
||||
${DPDK_LIBRARIES}
|
||||
${LIB_AS_NEEDED_POST}
|
||||
)
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}"
|
||||
"${libraries_to_link}" "${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME fd-net-device
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK ${libraries_to_link}
|
||||
TEST_SOURCES ${test_sources}
|
||||
MODULE_ENABLED_FEATURES ${module_enabled_features}
|
||||
)
|
||||
|
||||
if(${ENABLE_DPDKDEVNET})
|
||||
target_include_directories(
|
||||
${libfd-net-device-obj} PRIVATE ${DPDK_INCLUDE_DIRS}
|
||||
${libfd-net-device-obj}
|
||||
PRIVATE ${DPDK_INCLUDE_DIRS}
|
||||
)
|
||||
target_compile_options(
|
||||
${libfd-net-device-obj}
|
||||
PRIVATE ${DPDK_CFLAGS}
|
||||
)
|
||||
target_compile_options(${libfd-net-device-obj} PRIVATE ${DPDK_CFLAGS})
|
||||
endif()
|
||||
|
||||
list(LENGTH fd-net-device_creators num_creators)
|
||||
if(${num_creators} GREATER 0)
|
||||
add_dependencies(${libfd-net-device} ${fd-net-device_creators})
|
||||
list(
|
||||
LENGTH
|
||||
fd-net-device_creators
|
||||
num_creators
|
||||
)
|
||||
if(${num_creators}
|
||||
GREATER
|
||||
0
|
||||
)
|
||||
add_dependencies(
|
||||
${libfd-net-device}
|
||||
${fd-net-device_creators}
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@@ -1,101 +1,112 @@
|
||||
include_directories(${DPDK_INCLUDE_DIRS})
|
||||
|
||||
set(name dummy-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libinternet-apps})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME dummy-network
|
||||
SOURCE_FILES dummy-network.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name fd2fd-onoff)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd2fd-onoff
|
||||
SOURCE_FILES fd2fd-onoff.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
if(${ENABLE_REALTIME})
|
||||
set(name realtime-dummy-network)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libinternet-apps})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME realtime-dummy-network
|
||||
SOURCE_FILES realtime-dummy-network.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name realtime-fd2fd-onoff)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME realtime-fd2fd-onoff
|
||||
SOURCE_FILES realtime-fd2fd-onoff.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${ENABLE_EMU})
|
||||
set(name fd-emu-ping)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libinternet-apps})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-emu-ping
|
||||
SOURCE_FILES fd-emu-ping.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name fd-emu-udp-echo)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-emu-udp-echo
|
||||
SOURCE_FILES fd-emu-udp-echo.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name fd-emu-onoff)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-emu-onoff
|
||||
SOURCE_FILES fd-emu-onoff.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name fd-emu-send)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libapplications}
|
||||
${libinternet-apps} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-emu-send
|
||||
SOURCE_FILES fd-emu-send.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libinternet-apps}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name fd-emu-tc)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libapplications}
|
||||
${libinternet-apps} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-emu-tc
|
||||
SOURCE_FILES fd-emu-tc.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libinternet-apps}
|
||||
${libtraffic-control}
|
||||
)
|
||||
endif()
|
||||
|
||||
if(${ENABLE_TAP})
|
||||
set(name fd-tap-ping)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libinternet-apps})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-tap-ping
|
||||
SOURCE_FILES fd-tap-ping.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name fd-tap-ping6)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libfd-net-device} ${libinternet} ${libinternet-apps}
|
||||
${libcsma}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fd-tap-ping6
|
||||
SOURCE_FILES fd-tap-ping6.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libfd-net-device}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
${libcsma}
|
||||
)
|
||||
endif()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name flow-monitor)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME flow-monitor
|
||||
SOURCE_FILES
|
||||
helper/flow-monitor-helper.cc
|
||||
model/flow-classifier.cc
|
||||
model/flow-monitor.cc
|
||||
@@ -9,9 +9,7 @@ set(source_files
|
||||
model/ipv4-flow-probe.cc
|
||||
model/ipv6-flow-classifier.cc
|
||||
model/ipv6-flow-probe.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/flow-monitor-helper.h
|
||||
model/flow-classifier.h
|
||||
model/flow-monitor.h
|
||||
@@ -20,12 +18,6 @@ set(header_files
|
||||
model/ipv4-flow-probe.h
|
||||
model/ipv6-flow-classifier.h
|
||||
model/ipv6-flow-probe.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet} ${libconfig-store})
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${libconfig-store}
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name internet-apps)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME internet-apps
|
||||
SOURCE_FILES
|
||||
helper/dhcp-helper.cc
|
||||
helper/ping6-helper.cc
|
||||
helper/radvd-helper.cc
|
||||
@@ -15,9 +15,7 @@ set(source_files
|
||||
model/radvd.cc
|
||||
model/v4ping.cc
|
||||
model/v4traceroute.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/dhcp-helper.h
|
||||
helper/ping6-helper.h
|
||||
helper/radvd-helper.h
|
||||
@@ -32,12 +30,7 @@ set(header_files
|
||||
model/radvd.h
|
||||
model/v4ping.h
|
||||
model/v4traceroute.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet})
|
||||
|
||||
set(test_sources test/dhcp-test.cc test/ipv6-radvd-test.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
TEST_SOURCES test/dhcp-test.cc
|
||||
test/ipv6-radvd-test.cc
|
||||
)
|
||||
|
||||
@@ -1,17 +1,18 @@
|
||||
set(name dhcp-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libinternet-apps} ${libcsma}
|
||||
${libpoint-to-point} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME dhcp-example
|
||||
SOURCE_FILES dhcp-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name traceroute-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
build_lib_example(
|
||||
NAME traceroute-example
|
||||
SOURCE_FILES traceroute-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libaodv}
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
@@ -20,6 +21,3 @@ set(libraries_to_link
|
||||
${libwifi}
|
||||
${libinternet-apps}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
set(name internet)
|
||||
set(name)
|
||||
|
||||
set(source_files
|
||||
helper/internet-stack-helper.cc
|
||||
@@ -255,10 +255,6 @@ set(header_files
|
||||
model/windowed-filter.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${libcore} ${libbridge}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(test_sources
|
||||
test/global-route-manager-impl-test-suite.cc
|
||||
test/icmp-test.cc
|
||||
@@ -334,6 +330,14 @@ set(test_sources
|
||||
test/udp-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME internet
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcore}
|
||||
${libbridge}
|
||||
${libtraffic-control}
|
||||
TEST_SOURCES ${test_sources}
|
||||
)
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
set(name main-simple)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libinternet} ${libapplications})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME main-simple
|
||||
SOURCE_FILES main-simple.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name lr-wpan)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME lr-wpan
|
||||
SOURCE_FILES
|
||||
helper/lr-wpan-helper.cc
|
||||
model/lr-wpan-csmaca.cc
|
||||
model/lr-wpan-error-model.cc
|
||||
@@ -15,9 +15,7 @@ set(source_files
|
||||
model/lr-wpan-phy.cc
|
||||
model/lr-wpan-spectrum-signal-parameters.cc
|
||||
model/lr-wpan-spectrum-value-helper.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/lr-wpan-helper.h
|
||||
model/lr-wpan-csmaca.h
|
||||
model/lr-wpan-error-model.h
|
||||
@@ -32,13 +30,13 @@ set(header_files
|
||||
model/lr-wpan-phy.h
|
||||
model/lr-wpan-spectrum-signal-parameters.h
|
||||
model/lr-wpan-spectrum-value-helper.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${libcore} ${libmobility} ${libspectrum}
|
||||
${libpropagation}
|
||||
)
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libspectrum}
|
||||
${libpropagation}
|
||||
TEST_SOURCES
|
||||
test/lr-wpan-ack-test.cc
|
||||
test/lr-wpan-cca-test.cc
|
||||
test/lr-wpan-collision-test.cc
|
||||
@@ -50,7 +48,3 @@ set(test_sources
|
||||
test/lr-wpan-ifs-test.cc
|
||||
test/lr-wpan-slotted-csmaca-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,39 +1,30 @@
|
||||
set(name lr-wpan-data)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblr-wpan})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
lr-wpan-data
|
||||
lr-wpan-packet-print
|
||||
lr-wpan-phy-test
|
||||
)
|
||||
|
||||
set(name lr-wpan-error-distance-plot)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblr-wpan} ${libstats})
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK ${liblr-wpan}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME lr-wpan-error-distance-plot
|
||||
SOURCE_FILES lr-wpan-error-distance-plot.cc
|
||||
LIBRARIES_TO_LINK ${liblr-wpan}
|
||||
${libstats}
|
||||
)
|
||||
|
||||
set(name lr-wpan-error-model-plot)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblr-wpan} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lr-wpan-packet-print)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblr-wpan})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lr-wpan-phy-test)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblr-wpan})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME lr-wpan-error-model-plot
|
||||
SOURCE_FILES lr-wpan-error-model-plot.cc
|
||||
LIBRARIES_TO_LINK ${liblr-wpan}
|
||||
${libstats}
|
||||
)
|
||||
|
||||
@@ -1,9 +1,13 @@
|
||||
set(name lte)
|
||||
|
||||
if(${ENABLE_EMU})
|
||||
set(emu_sources helper/emu-epc-helper.cc)
|
||||
set(emu_headers helper/emu-epc-helper.h)
|
||||
set(emu_libraries ${libfd-net-device})
|
||||
set(emu_sources
|
||||
helper/emu-epc-helper.cc
|
||||
)
|
||||
set(emu_headers
|
||||
helper/emu-epc-helper.h
|
||||
)
|
||||
set(emu_libraries
|
||||
${libfd-net-device}
|
||||
)
|
||||
endif()
|
||||
|
||||
set(source_files
|
||||
@@ -268,20 +272,6 @@ set(header_files
|
||||
model/tta-ff-mac-scheduler.h
|
||||
)
|
||||
|
||||
set(libraries_to_link
|
||||
${emu_libraries}
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libspectrum}
|
||||
${libstats}
|
||||
${libbuildings}
|
||||
${libvirtual-net-device}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
${libcsma}
|
||||
)
|
||||
|
||||
set(test_sources
|
||||
test/epc-test-gtpu.cc
|
||||
test/epc-test-s1u-downlink.cc
|
||||
@@ -342,6 +332,21 @@ set(test_sources
|
||||
test/test-lte-x2-handover.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME lte
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK
|
||||
${emu_libraries}
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${libspectrum}
|
||||
${libstats}
|
||||
${libbuildings}
|
||||
${libvirtual-net-device}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
${libinternet}
|
||||
${libcsma}
|
||||
TEST_SOURCES ${test_sources}
|
||||
)
|
||||
|
||||
@@ -1,177 +1,43 @@
|
||||
set(name lena-cqi-threshold)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
lena-cqi-threshold
|
||||
lena-dual-stripe
|
||||
lena-fading
|
||||
lena-intercell-interference
|
||||
lena-pathloss-traces
|
||||
lena-profiling
|
||||
lena-rem
|
||||
lena-rem-sector-antenna
|
||||
lena-rlc-traces
|
||||
lena-simple
|
||||
lena-simple-epc
|
||||
lena-deactivate-bearer
|
||||
lena-x2-handover
|
||||
lena-x2-handover-measures
|
||||
lena-frequency-reuse
|
||||
lena-distributed-ffr
|
||||
lena-uplink-power-control
|
||||
lena-ipv6-addr-conf
|
||||
lena-ipv6-ue-rh
|
||||
lena-ipv6-ue-ue
|
||||
lena-radio-link-failure
|
||||
)
|
||||
|
||||
set(name lena-dual-stripe)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-fading)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-intercell-interference)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-pathloss-traces)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-profiling)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-rem)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-rem-sector-antenna)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-rlc-traces)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-simple)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-simple-epc)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-deactivate-bearer)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-x2-handover)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-x2-handover-measures)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-frequency-reuse)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-distributed-ffr)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-uplink-power-control)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-ipv6-addr-conf)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-ipv6-ue-rh)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-ipv6-ue-ue)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lena-radio-link-failure)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK ${liblte}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
if(${ENABLE_EMU})
|
||||
set(name lena-simple-epc-emu)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${liblte} ${fd-net-device})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME lena-simple-epc-emu
|
||||
SOURCE_FILES lena-simple-epc-emu.cc
|
||||
LIBRARIES_TO_LINK ${liblte}
|
||||
${fd-net-device}
|
||||
)
|
||||
endif()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name mesh)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME mesh
|
||||
SOURCE_FILES
|
||||
helper/dot11s/dot11s-installer.cc
|
||||
helper/flame/flame-installer.cc
|
||||
helper/mesh-helper.cc
|
||||
@@ -34,9 +34,7 @@ set(source_files
|
||||
model/mesh-point-device.cc
|
||||
model/mesh-wifi-beacon.cc
|
||||
model/mesh-wifi-interface-mac.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/dot11s/dot11s-installer.h
|
||||
helper/flame/flame-installer.h
|
||||
helper/mesh-helper.h
|
||||
@@ -67,11 +65,11 @@ set(header_files
|
||||
model/mesh-wifi-beacon.h
|
||||
model/mesh-wifi-interface-mac-plugin.h
|
||||
model/mesh-wifi-interface-mac.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet} ${libwifi} ${libapplications})
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libwifi}
|
||||
${libapplications}
|
||||
TEST_SOURCES
|
||||
test/dot11s/dot11s-test-suite.cc
|
||||
test/dot11s/hwmp-proactive-regression.cc
|
||||
test/dot11s/hwmp-reactive-regression.cc
|
||||
@@ -84,7 +82,3 @@ set(test_sources
|
||||
test/flame/regression.cc
|
||||
test/mesh-information-element-vector-test-suite.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
set(name mesh)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libmobility} ${libwifi} ${libmesh}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME mesh
|
||||
SOURCE_FILES mesh.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libmobility}
|
||||
${libwifi}
|
||||
${libmesh}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name mobility)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME mobility
|
||||
SOURCE_FILES
|
||||
helper/group-mobility-helper.cc
|
||||
helper/mobility-helper.cc
|
||||
helper/ns2-mobility-helper.cc
|
||||
@@ -21,9 +21,7 @@ set(source_files
|
||||
model/steady-state-random-waypoint-mobility-model.cc
|
||||
model/waypoint-mobility-model.cc
|
||||
model/waypoint.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/group-mobility-helper.h
|
||||
helper/mobility-helper.h
|
||||
helper/ns2-mobility-helper.h
|
||||
@@ -44,11 +42,8 @@ set(header_files
|
||||
model/steady-state-random-waypoint-mobility-model.h
|
||||
model/waypoint-mobility-model.h
|
||||
model/waypoint.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork})
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
TEST_SOURCES
|
||||
test/box-line-intersection-test.cc
|
||||
test/geo-to-cartesian-test.cc
|
||||
test/mobility-test-suite.cc
|
||||
@@ -58,7 +53,3 @@ set(test_sources
|
||||
test/steady-state-random-waypoint-mobility-model-test.cc
|
||||
test/waypoint-mobility-model-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,55 +1,42 @@
|
||||
set(name bonnmotion-ns2-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility})
|
||||
set(base_examples
|
||||
bonnmotion-ns2-example
|
||||
main-random-topology
|
||||
main-random-walk
|
||||
ns2-mobility-trace
|
||||
)
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
${libmobility}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME main-grid-topology
|
||||
SOURCE_FILES main-grid-topology.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libnetwork}
|
||||
)
|
||||
|
||||
set(name main-grid-topology)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libnetwork})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME mobility-trace-example
|
||||
SOURCE_FILES mobility-trace-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libnetwork}
|
||||
)
|
||||
|
||||
set(name main-random-topology)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name main-random-walk)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name mobility-trace-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libnetwork})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name ns2-mobility-trace)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name reference-point-group-mobility-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libmobility})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME reference-point-group-mobility-example
|
||||
SOURCE_FILES reference-point-group-mobility-example.cc
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${libmobility}
|
||||
)
|
||||
|
||||
@@ -1,8 +1,15 @@
|
||||
set(name mpi)
|
||||
|
||||
include_directories(${MPI_CXX_INCLUDE_DIRS})
|
||||
|
||||
set(source_files
|
||||
set(example_as_test_suite)
|
||||
if(${ENABLE_EXAMPLES})
|
||||
set(example_as_test_suite
|
||||
test/mpi-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
|
||||
build_lib(
|
||||
LIBNAME mpi
|
||||
SOURCE_FILES
|
||||
model/distributed-simulator-impl.cc
|
||||
model/granted-time-window-mpi-interface.cc
|
||||
model/mpi-interface.cc
|
||||
@@ -12,21 +19,13 @@ set(source_files
|
||||
model/parallel-communication-interface.h
|
||||
model/remote-channel-bundle-manager.cc
|
||||
model/remote-channel-bundle.cc
|
||||
)
|
||||
|
||||
set(header_files model/mpi-interface.h model/mpi-receiver.h
|
||||
model/parallel-communication-interface.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libcore} ${libnetwork} ${MPI_CXX_LIBRARIES})
|
||||
|
||||
set(example_as_test_suite)
|
||||
if(${ENABLE_EXAMPLES})
|
||||
set(example_as_test_suite test/mpi-test-suite.cc)
|
||||
endif()
|
||||
|
||||
set(test_sources ${example_as_test_suite})
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
HEADER_FILES
|
||||
model/mpi-interface.h
|
||||
model/mpi-receiver.h
|
||||
model/parallel-communication-interface.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libnetwork}
|
||||
${MPI_CXX_LIBRARIES}
|
||||
TEST_SOURCES ${example_as_test_suite}
|
||||
)
|
||||
|
||||
@@ -1,20 +1,35 @@
|
||||
include_directories(${MPI_CXX_INCLUDE_DIRS})
|
||||
link_libraries(${MPI_CXX_LIBRARIES})
|
||||
|
||||
set(name simple-distributed)
|
||||
set(source_files ${name}.cc mpi-test-fixtures.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libmpi} ${libpoint-to-point} ${libinternet}
|
||||
${libnix-vector-routing} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
simple-distributed
|
||||
simple-distributed-mpi-comm
|
||||
nms-p2p-nix-distributed
|
||||
simple-distributed-empty-node
|
||||
)
|
||||
|
||||
set(name third-distributed)
|
||||
set(source_files ${name}.cc mpi-test-fixtures.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
mpi-test-fixtures.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libmpi}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libnix-vector-routing}
|
||||
${libapplications}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
build_lib_example(
|
||||
NAME third-distributed
|
||||
SOURCE_FILES third-distributed.cc
|
||||
mpi-test-fixtures.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libmpi}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
@@ -23,36 +38,3 @@ set(libraries_to_link
|
||||
${libcsma}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name nms-p2p-nix-distributed)
|
||||
set(source_files ${name}.cc mpi-test-fixtures.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libmpi} ${libpoint-to-point} ${libinternet}
|
||||
${libnix-vector-routing} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name simple-distributed-empty-node)
|
||||
set(source_files ${name}.cc mpi-test-fixtures.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libmpi} ${libpoint-to-point} ${libinternet}
|
||||
${libnix-vector-routing} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name simple-distributed-mpi-comm)
|
||||
set(source_files ${name}.cc mpi-test-fixtures.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libmpi} ${libpoint-to-point} ${libinternet}
|
||||
${libnix-vector-routing} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
set(name netanim)
|
||||
|
||||
set(source_files model/animation-interface.cc)
|
||||
|
||||
set(header_files model/animation-interface.h)
|
||||
|
||||
set(libraries_to_link
|
||||
build_lib(
|
||||
LIBNAME netanim
|
||||
SOURCE_FILES model/animation-interface.cc
|
||||
HEADER_FILES model/animation-interface.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libmobility}
|
||||
${libwimax}
|
||||
@@ -16,10 +14,5 @@ set(libraries_to_link
|
||||
${liblr-wpan}
|
||||
${libwave}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
|
||||
set(test_sources test/netanim-test.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
TEST_SOURCES test/netanim-test.cc
|
||||
)
|
||||
|
||||
@@ -1,37 +1,29 @@
|
||||
set(name dumbbell-animation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetanim} ${libapplications}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
dumbbell-animation
|
||||
grid-animation
|
||||
star-animation
|
||||
colors-link-description
|
||||
resources-counters
|
||||
)
|
||||
|
||||
set(name grid-animation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetanim} ${libapplications}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetanim}
|
||||
${libapplications}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
set(name star-animation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetanim} ${libapplications}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name wireless-animation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
NAME wireless-animation
|
||||
SOURCE_FILES wireless-animation.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetanim}
|
||||
${libapplications}
|
||||
${libpoint-to-point}
|
||||
@@ -40,36 +32,14 @@ set(libraries_to_link
|
||||
${libmobility}
|
||||
${libnetwork}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name uan-animation)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetanim} ${libinternet} ${libmobility}
|
||||
${libapplications} ${libuan}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name colors-link-description)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetanim} ${libapplications}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name resources-counters)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetanim} ${libapplications}
|
||||
${libpoint-to-point-layout}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME uan-animation
|
||||
SOURCE_FILES uan-animation.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetanim}
|
||||
${libinternet}
|
||||
${libmobility}
|
||||
${libapplications}
|
||||
${libuan}
|
||||
)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
set(name network)
|
||||
set(name)
|
||||
|
||||
set(source_files
|
||||
helper/application-container.cc
|
||||
@@ -148,9 +148,13 @@ set(header_files
|
||||
utils/sll-header.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libcore} ${libstats})
|
||||
|
||||
set(test_sources
|
||||
build_lib(
|
||||
LIBNAME network
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
${libstats}
|
||||
TEST_SOURCES
|
||||
test/bit-serializer-test.cc
|
||||
test/buffer-test.cc
|
||||
test/drop-tail-queue-test-suite.cc
|
||||
@@ -165,7 +169,3 @@ set(test_sources
|
||||
test/sequence-number-test-suite.cc
|
||||
test/test-data-rate.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,36 +1,19 @@
|
||||
set(header_files)
|
||||
|
||||
set(name bit-serializer)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libcore} ${libnetwork})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
bit-serializer
|
||||
main-packet-header
|
||||
main-packet-tag
|
||||
packet-socket-apps
|
||||
lollipop-comparisions
|
||||
)
|
||||
|
||||
set(name main-packet-header)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libnetwork})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name main-packet-tag)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libnetwork})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name packet-socket-apps)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libnetwork} ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name lollipop-comparisions)
|
||||
set(source_files ${name}.cc)
|
||||
set(libraries_to_link ${libnetwork} ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${libcore}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
@@ -1,17 +1,27 @@
|
||||
set(name nix-vector-routing)
|
||||
set(name)
|
||||
|
||||
set(source_files helper/nix-vector-helper.cc model/nix-vector-routing.cc)
|
||||
set(source_files)
|
||||
|
||||
set(header_files helper/nix-vector-helper.h model/nix-vector-routing.h)
|
||||
set(header_files)
|
||||
|
||||
set(deprecated_header_files helper/ipv4-nix-vector-helper.h
|
||||
model/ipv4-nix-vector-routing.h
|
||||
set(deprecated_header_files)
|
||||
|
||||
set(libraries_to_link
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet})
|
||||
|
||||
set(test_sources test/nix-test.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
set(test_sources
|
||||
test/nix-test.cc
|
||||
)
|
||||
|
||||
build_lib(
|
||||
LIBNAME nix-vector-routing
|
||||
SOURCE_FILES helper/nix-vector-helper.cc
|
||||
model/nix-vector-routing.cc
|
||||
HEADER_FILES helper/nix-vector-helper.h
|
||||
model/nix-vector-routing.h
|
||||
DEPRECATED_HEADER_FILES helper/ipv4-nix-vector-helper.h
|
||||
model/ipv4-nix-vector-routing.h
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
TEST_SOURCES test/nix-test.cc
|
||||
)
|
||||
|
||||
@@ -1,13 +1,20 @@
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libnix-vector-routing}
|
||||
set(base_examples
|
||||
nix-simple
|
||||
nix-simple-multi-address
|
||||
nms-p2p-nix
|
||||
)
|
||||
|
||||
set(nix_examples nix-simple nix-simple-multi-address nms-p2p-nix)
|
||||
|
||||
foreach(example ${nix_examples})
|
||||
set(source_files ${example}.cc)
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
"${example}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libnix-vector-routing}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
set(name olsr)
|
||||
|
||||
set(source_files helper/olsr-helper.cc model/olsr-header.cc
|
||||
model/olsr-routing-protocol.cc model/olsr-state.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
helper/olsr-helper.h model/olsr-header.h model/olsr-repositories.h
|
||||
model/olsr-routing-protocol.h model/olsr-state.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet})
|
||||
|
||||
set(test_sources
|
||||
test/regression-test-suite.cc test/bug780-test.cc
|
||||
test/hello-regression-test.cc test/olsr-header-test-suite.cc
|
||||
test/olsr-routing-protocol-test-suite.cc test/tc-regression-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME olsr
|
||||
SOURCE_FILES
|
||||
helper/olsr-helper.cc
|
||||
model/olsr-header.cc
|
||||
model/olsr-routing-protocol.cc
|
||||
model/olsr-state.cc
|
||||
HEADER_FILES
|
||||
helper/olsr-helper.h
|
||||
model/olsr-header.h
|
||||
model/olsr-repositories.h
|
||||
model/olsr-routing-protocol.h
|
||||
model/olsr-state.h
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
TEST_SOURCES
|
||||
test/regression-test-suite.cc
|
||||
test/bug780-test.cc
|
||||
test/hello-regression-test.cc
|
||||
test/olsr-header-test-suite.cc
|
||||
test/olsr-routing-protocol-test-suite.cc
|
||||
test/tc-regression-test.cc
|
||||
)
|
||||
|
||||
@@ -1,19 +1,21 @@
|
||||
set(name olsr-hna)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libmobility} ${libwifi} ${libcsma}
|
||||
${libolsr}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME olsr-hna
|
||||
SOURCE_FILES olsr-hna.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libmobility}
|
||||
${libwifi}
|
||||
${libcsma}
|
||||
${libolsr}
|
||||
)
|
||||
|
||||
set(name simple-point-to-point-olsr)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libolsr}
|
||||
${libapplications} ${libwifi}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME simple-point-to-point-olsr
|
||||
SOURCE_FILES simple-point-to-point-olsr.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libolsr}
|
||||
${libapplications}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
@@ -1,42 +1,61 @@
|
||||
set(NS3_WITH_OPENFLOW "" CACHE PATH "Build with Openflow support")
|
||||
set(NS3_OPENFLOW "OFF" CACHE INTERNAL
|
||||
"ON if Openflow is found in NS3_WITH_OPENFLOW"
|
||||
set(NS3_WITH_OPENFLOW
|
||||
""
|
||||
CACHE PATH
|
||||
"Build with Openflow support"
|
||||
)
|
||||
set(NS3_OPENFLOW
|
||||
"OFF"
|
||||
CACHE INTERNAL
|
||||
"ON if Openflow is found in NS3_WITH_OPENFLOW"
|
||||
)
|
||||
|
||||
find_external_library_header_and_library(
|
||||
"openflow" "openflow.h" "openflow" "${NS3_WITH_OPENFLOW}"
|
||||
"openflow"
|
||||
"openflow.h"
|
||||
"openflow"
|
||||
"${NS3_WITH_OPENFLOW}"
|
||||
)
|
||||
if(NOT
|
||||
(openflow_library
|
||||
AND openflow_header)
|
||||
)
|
||||
if(NOT (openflow_library AND openflow_header))
|
||||
message(STATUS "Openflow was not found")
|
||||
return()
|
||||
endif()
|
||||
|
||||
check_include_file_cxx(boost/static_assert.hpp BOOST_STATIC_ASSERT)
|
||||
if(NOT BOOST_STATIC_ASSERT)
|
||||
check_include_file_cxx(
|
||||
boost/static_assert.hpp
|
||||
BOOST_STATIC_ASSERT
|
||||
)
|
||||
if(NOT
|
||||
BOOST_STATIC_ASSERT
|
||||
)
|
||||
message(STATUS "Openflow requires Boost static_assert.hpp")
|
||||
return()
|
||||
endif()
|
||||
|
||||
include_directories(${openflow_include_directories})
|
||||
add_definitions(-DNS3_OPENFLOW -DENABLE_OPENFLOW)
|
||||
set(NS3_OPENFLOW "ON" CACHE INTERNAL
|
||||
"ON if Openflow is found in NS3_WITH_OPENFLOW"
|
||||
add_definitions(
|
||||
-DNS3_OPENFLOW
|
||||
-DENABLE_OPENFLOW
|
||||
)
|
||||
set(NS3_OPENFLOW
|
||||
"ON"
|
||||
CACHE INTERNAL
|
||||
"ON if Openflow is found in NS3_WITH_OPENFLOW"
|
||||
)
|
||||
|
||||
set(name openflow)
|
||||
|
||||
set(source_files helper/openflow-switch-helper.cc model/openflow-interface.cc
|
||||
model/openflow-switch-net-device.cc
|
||||
)
|
||||
|
||||
set(header_files helper/openflow-switch-helper.h model/openflow-interface.h
|
||||
model/openflow-switch-net-device.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet} ${openflow_library})
|
||||
|
||||
set(test_sources test/openflow-switch-test-suite.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME openflow
|
||||
SOURCE_FILES
|
||||
helper/openflow-switch-helper.cc
|
||||
model/openflow-interface.cc
|
||||
model/openflow-switch-net-device.cc
|
||||
HEADER_FILES
|
||||
helper/openflow-switch-helper.h
|
||||
model/openflow-interface.h
|
||||
model/openflow-switch-net-device.h
|
||||
LIBRARIES_TO_LINK ${libinternet}
|
||||
${openflow_library}
|
||||
TEST_SOURCES test/openflow-switch-test-suite.cc
|
||||
)
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
set(name openflow-switch)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libopenflow} ${libinternet} ${libcsma}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME openflow-switch
|
||||
SOURCE_FILES openflow-switch.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libopenflow}
|
||||
${libinternet}
|
||||
${libcsma}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
@@ -1,15 +1,23 @@
|
||||
set(name point-to-point-layout)
|
||||
set(name)
|
||||
|
||||
set(source_files model/point-to-point-dumbbell.cc model/point-to-point-grid.cc
|
||||
model/point-to-point-star.cc
|
||||
)
|
||||
|
||||
set(header_files model/point-to-point-dumbbell.h model/point-to-point-grid.h
|
||||
model/point-to-point-star.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet} ${libpoint-to-point} ${libmobility})
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
set(source_files)
|
||||
|
||||
set(header_files)
|
||||
|
||||
set(libraries_to_link)
|
||||
|
||||
build_lib(
|
||||
LIBNAME point-to-point-layout
|
||||
SOURCE_FILES
|
||||
model/point-to-point-dumbbell.cc
|
||||
model/point-to-point-grid.cc
|
||||
model/point-to-point-star.cc
|
||||
HEADER_FILES
|
||||
model/point-to-point-dumbbell.h
|
||||
model/point-to-point-grid.h
|
||||
model/point-to-point-star.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libpoint-to-point}
|
||||
${libmobility}
|
||||
)
|
||||
|
||||
@@ -1,33 +1,36 @@
|
||||
set(name point-to-point)
|
||||
|
||||
set(mpi_sources)
|
||||
set(mpi_headers)
|
||||
set(mpi_libraries)
|
||||
set(mpi_include_directories)
|
||||
|
||||
if(${ENABLE_MPI})
|
||||
set(mpi_sources model/point-to-point-remote-channel.cc)
|
||||
set(mpi_headers model/point-to-point-remote-channel.h)
|
||||
set(mpi_libraries ${libmpi} ${MPI_CXX_LIBRARIES})
|
||||
set(mpi_sources
|
||||
model/point-to-point-remote-channel.cc
|
||||
)
|
||||
set(mpi_headers
|
||||
model/point-to-point-remote-channel.h
|
||||
)
|
||||
set(mpi_libraries
|
||||
${libmpi}
|
||||
${MPI_CXX_LIBRARIES}
|
||||
)
|
||||
include_directories(${MPI_CXX_INCLUDE_DIRS})
|
||||
endif()
|
||||
|
||||
set(source_files
|
||||
${mpi_sources} helper/point-to-point-helper.cc
|
||||
model/point-to-point-channel.cc model/point-to-point-net-device.cc
|
||||
build_lib(
|
||||
LIBNAME point-to-point
|
||||
SOURCE_FILES
|
||||
${mpi_sources}
|
||||
helper/point-to-point-helper.cc
|
||||
model/point-to-point-channel.cc
|
||||
model/point-to-point-net-device.cc
|
||||
model/ppp-header.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
${mpi_headers} helper/point-to-point-helper.h
|
||||
model/point-to-point-channel.h model/point-to-point-net-device.h
|
||||
HEADER_FILES
|
||||
${mpi_headers}
|
||||
helper/point-to-point-helper.h
|
||||
model/point-to-point-channel.h
|
||||
model/point-to-point-net-device.h
|
||||
model/ppp-header.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${mpi_libraries})
|
||||
|
||||
set(test_sources test/point-to-point-test.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${mpi_libraries}
|
||||
TEST_SOURCES test/point-to-point-test.cc
|
||||
)
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
set(name main-attribute-value)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libpoint-to-point})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME main-attribute-value
|
||||
SOURCE_FILES main-attribute-value.cc
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${libpoint-to-point}
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name propagation)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME propagation
|
||||
SOURCE_FILES
|
||||
model/channel-condition-model.cc
|
||||
model/cost231-propagation-loss-model.cc
|
||||
model/itu-r-1411-los-propagation-loss-model.cc
|
||||
@@ -14,9 +14,7 @@ set(source_files
|
||||
model/propagation-loss-model.cc
|
||||
model/three-gpp-propagation-loss-model.cc
|
||||
model/three-gpp-v2v-propagation-loss-model.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
model/channel-condition-model.h
|
||||
model/cost231-propagation-loss-model.h
|
||||
model/itu-r-1411-los-propagation-loss-model.h
|
||||
@@ -32,11 +30,9 @@ set(header_files
|
||||
model/propagation-loss-model.h
|
||||
model/three-gpp-propagation-loss-model.h
|
||||
model/three-gpp-v2v-propagation-loss-model.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${libmobility})
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${libmobility}
|
||||
TEST_SOURCES
|
||||
test/channel-condition-model-test-suite.cc
|
||||
test/itu-r-1411-los-test-suite.cc
|
||||
test/itu-r-1411-nlos-over-rooftop-test-suite.cc
|
||||
@@ -47,7 +43,3 @@ set(test_sources
|
||||
test/three-gpp-propagation-loss-model-test-suite.cc
|
||||
test/three-gpp-propagation-loss-model-test-suite.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,17 +1,20 @@
|
||||
set(name main-propagation-loss)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpropagation} ${libconfig-store}
|
||||
${libstats} ${libmobility} ${libbuildings}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME main-propagation-loss
|
||||
SOURCE_FILES main-propagation-loss.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpropagation}
|
||||
${libconfig-store}
|
||||
${libstats}
|
||||
${libmobility}
|
||||
${libbuildings}
|
||||
)
|
||||
|
||||
set(name jakes-propagation-model-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcore} ${libpropagation} ${libbuildings})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME jakes-propagation-model-example
|
||||
SOURCE_FILES jakes-propagation-model-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libpropagation}
|
||||
${libbuildings}
|
||||
)
|
||||
|
||||
@@ -1,26 +1,29 @@
|
||||
set(name sixlowpan)
|
||||
|
||||
set(source_files helper/sixlowpan-helper.cc model/sixlowpan-header.cc
|
||||
model/sixlowpan-net-device.cc
|
||||
)
|
||||
|
||||
set(header_files helper/sixlowpan-helper.h model/sixlowpan-header.h
|
||||
model/sixlowpan-net-device.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libinternet} ${libinternet} ${libcore})
|
||||
|
||||
set(example_as_test_suite)
|
||||
if(${ENABLE_EXAMPLES})
|
||||
set(example_as_test_suite test/sixlowpan-examples-test-suite.cc)
|
||||
set(example_as_test_suite
|
||||
test/sixlowpan-examples-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
|
||||
set(test_sources
|
||||
${example_as_test_suite} test/mock-net-device.cc
|
||||
test/sixlowpan-fragmentation-test.cc test/sixlowpan-hc1-test.cc
|
||||
test/sixlowpan-iphc-stateful-test.cc test/sixlowpan-iphc-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME sixlowpan
|
||||
SOURCE_FILES
|
||||
helper/sixlowpan-helper.cc
|
||||
model/sixlowpan-header.cc
|
||||
model/sixlowpan-net-device.cc
|
||||
HEADER_FILES
|
||||
helper/sixlowpan-helper.h
|
||||
model/sixlowpan-header.h
|
||||
model/sixlowpan-net-device.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libinternet}
|
||||
${libcore}
|
||||
TEST_SOURCES
|
||||
${example_as_test_suite}
|
||||
test/mock-net-device.cc
|
||||
test/sixlowpan-fragmentation-test.cc
|
||||
test/sixlowpan-hc1-test.cc
|
||||
test/sixlowpan-iphc-stateful-test.cc
|
||||
test/sixlowpan-iphc-test.cc
|
||||
)
|
||||
|
||||
@@ -1,39 +1,44 @@
|
||||
set(name example-sixlowpan)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libsixlowpan} ${libinternet} ${libcsma}
|
||||
${libinternet-apps}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME example-sixlowpan
|
||||
SOURCE_FILES example-sixlowpan.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libsixlowpan}
|
||||
${libinternet}
|
||||
${libcsma}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name example-ping-lr-wpan)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libsixlowpan} ${libinternet}
|
||||
${liblr-wpan} ${libinternet-apps}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME example-ping-lr-wpan
|
||||
SOURCE_FILES example-ping-lr-wpan.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libsixlowpan}
|
||||
${libinternet}
|
||||
${liblr-wpan}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name example-ping-lr-wpan-beacon)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libsixlowpan} ${libinternet}
|
||||
${liblr-wpan} ${libinternet-apps}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME example-ping-lr-wpan-beacon
|
||||
SOURCE_FILES example-ping-lr-wpan-beacon.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libsixlowpan}
|
||||
${libinternet}
|
||||
${liblr-wpan}
|
||||
${libinternet-apps}
|
||||
)
|
||||
|
||||
set(name example-ping-lr-wpan-mesh-under)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libsixlowpan} ${libinternet}
|
||||
${liblr-wpan} ${libinternet-apps} ${libcsma}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME example-ping-lr-wpan-mesh-under
|
||||
SOURCE_FILES example-ping-lr-wpan-mesh-under.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libsixlowpan}
|
||||
${libinternet}
|
||||
${liblr-wpan}
|
||||
${libinternet-apps}
|
||||
${libcsma}
|
||||
)
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
set(name spectrum)
|
||||
|
||||
set(source_files
|
||||
helper/adhoc-aloha-noack-ideal-phy-helper.cc
|
||||
helper/spectrum-analyzer-helper.cc
|
||||
@@ -77,9 +75,13 @@ set(header_files
|
||||
test/spectrum-test.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libpropagation} ${libantenna})
|
||||
|
||||
set(test_sources
|
||||
build_lib(
|
||||
LIBNAME spectrum
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK ${libpropagation}
|
||||
${libantenna}
|
||||
TEST_SOURCES
|
||||
test/spectrum-ideal-phy-test.cc
|
||||
test/spectrum-interference-test.cc
|
||||
test/spectrum-value-test.cc
|
||||
@@ -88,7 +90,3 @@ set(test_sources
|
||||
test/tv-helper-distribution-test.cc
|
||||
test/tv-spectrum-transmitter-test.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,53 +1,57 @@
|
||||
set(name adhoc-aloha-ideal-phy)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libspectrum} ${libmobility} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME adhoc-aloha-ideal-phy
|
||||
SOURCE_FILES adhoc-aloha-ideal-phy.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libspectrum}
|
||||
${libmobility}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name adhoc-aloha-ideal-phy-matrix-propagation-loss-model)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libspectrum} ${libmobility} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME adhoc-aloha-ideal-phy-matrix-propagation-loss-model
|
||||
SOURCE_FILES adhoc-aloha-ideal-phy-matrix-propagation-loss-model.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libspectrum}
|
||||
${libmobility}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name adhoc-aloha-ideal-phy-with-microwave-oven)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libspectrum} ${libmobility} ${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME adhoc-aloha-ideal-phy-with-microwave-oven
|
||||
SOURCE_FILES adhoc-aloha-ideal-phy-with-microwave-oven.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libspectrum}
|
||||
${libmobility}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
set(name tv-trans-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libspectrum} ${libmobility} ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tv-trans-example
|
||||
SOURCE_FILES tv-trans-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libspectrum}
|
||||
${libmobility}
|
||||
${libcore}
|
||||
)
|
||||
|
||||
set(name tv-trans-regional-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libspectrum} ${libmobility} ${libcore})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tv-trans-regional-example
|
||||
SOURCE_FILES tv-trans-regional-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libspectrum}
|
||||
${libmobility}
|
||||
${libcore}
|
||||
)
|
||||
|
||||
set(name three-gpp-channel-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libspectrum} ${libmobility} ${libcore} ${liblte})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME three-gpp-channel-example
|
||||
SOURCE_FILES three-gpp-channel-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libspectrum}
|
||||
${libmobility}
|
||||
${libcore}
|
||||
${liblte}
|
||||
)
|
||||
|
||||
@@ -1,26 +1,52 @@
|
||||
set(name stats)
|
||||
|
||||
if(${NS3_SQLITE})
|
||||
find_package(SQLite3 QUIET)
|
||||
check_include_file_cxx(semaphore.h HAVE_SEMAPHORE_H)
|
||||
find_package(
|
||||
SQLite3
|
||||
QUIET
|
||||
)
|
||||
check_include_file_cxx(
|
||||
semaphore.h
|
||||
HAVE_SEMAPHORE_H
|
||||
)
|
||||
if(${SQLite3_FOUND})
|
||||
set(sqlite_sources model/sqlite-data-output.cc)
|
||||
set(sqlite_headers model/sqlite-data-output.h)
|
||||
set(sqlite_sources
|
||||
model/sqlite-data-output.cc
|
||||
)
|
||||
set(sqlite_headers
|
||||
model/sqlite-data-output.h
|
||||
)
|
||||
|
||||
include_directories(${SQLite3_INCLUDE_DIRS})
|
||||
set(sqlite_libraries ${SQLite3_LIBRARIES})
|
||||
set(sqlite_libraries
|
||||
${SQLite3_LIBRARIES}
|
||||
)
|
||||
|
||||
if(HAVE_SEMAPHORE_H)
|
||||
list(APPEND sqlite_sources model/sqlite-output.cc)
|
||||
list(APPEND sqlite_headers model/sqlite-output.h)
|
||||
list(
|
||||
APPEND
|
||||
sqlite_sources
|
||||
model/sqlite-output.cc
|
||||
)
|
||||
list(
|
||||
APPEND
|
||||
sqlite_headers
|
||||
model/sqlite-output.h
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
mark_as_advanced(ENABLE_SQLITE)
|
||||
if("${SQLite3_FOUND}")
|
||||
set(ENABLE_SQLITE True CACHE INTERNAL "")
|
||||
set(ENABLE_SQLITE
|
||||
True
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
else()
|
||||
set(ENABLE_SQLITE False CACHE INTERNAL "")
|
||||
set(ENABLE_SQLITE
|
||||
False
|
||||
CACHE INTERNAL
|
||||
""
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@@ -77,13 +103,15 @@ set(header_files
|
||||
model/uinteger-8-probe.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libcore} ${sqlite_libraries})
|
||||
|
||||
set(test_sources
|
||||
test/average-test-suite.cc test/basic-data-calculators-test-suite.cc
|
||||
test/double-probe-test-suite.cc test/histogram-test-suite.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME stats
|
||||
SOURCE_FILES ${source_files}
|
||||
HEADER_FILES ${header_files}
|
||||
LIBRARIES_TO_LINK ${libcore}
|
||||
${sqlite_libraries}
|
||||
TEST_SOURCES
|
||||
test/average-test-suite.cc
|
||||
test/basic-data-calculators-test-suite.cc
|
||||
test/double-probe-test-suite.cc
|
||||
test/histogram-test-suite.cc
|
||||
)
|
||||
|
||||
@@ -1,55 +1,26 @@
|
||||
set(name gnuplot-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME time-probe-example
|
||||
SOURCE_FILES time-probe-example.cc
|
||||
LIBRARIES_TO_LINK ${libstats}
|
||||
)
|
||||
|
||||
set(name double-probe-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
set(base_examples
|
||||
gnuplot-example
|
||||
double-probe-example
|
||||
gnuplot-aggregator-example
|
||||
gnuplot-helper-example
|
||||
file-aggregator-example
|
||||
file-helper-example
|
||||
)
|
||||
|
||||
set(name time-probe-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name gnuplot-aggregator-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name gnuplot-helper-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name file-aggregator-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name file-helper-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libnetwork} ${libstats})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${libstats}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
@@ -1,25 +1,29 @@
|
||||
set(name tap-bridge)
|
||||
|
||||
set(source_files helper/tap-bridge-helper.cc model/tap-bridge.cc
|
||||
model/tap-encode-decode.cc
|
||||
)
|
||||
|
||||
set(header_files helper/tap-bridge-helper.h model/tap-bridge.h
|
||||
model/tap-encode-decode.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libcore} ${libinternet} ${libnetwork})
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME tap-bridge
|
||||
SOURCE_FILES
|
||||
helper/tap-bridge-helper.cc
|
||||
model/tap-bridge.cc
|
||||
model/tap-encode-decode.cc
|
||||
HEADER_FILES
|
||||
helper/tap-bridge-helper.h
|
||||
model/tap-bridge.h
|
||||
model/tap-encode-decode.h
|
||||
LIBRARIES_TO_LINK
|
||||
${libcore}
|
||||
${libinternet}
|
||||
${libnetwork}
|
||||
)
|
||||
|
||||
add_definitions(
|
||||
-DTAP_CREATOR="${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/tap-bridge/ns${NS3_VER}-tap-creator${build_profile_suffix}"
|
||||
)
|
||||
add_executable(tap-creator model/tap-creator.cc model/tap-encode-decode.cc)
|
||||
set_runtime_outputdirectory(
|
||||
tap-creator ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/tap-bridge/ ""
|
||||
add_executable(
|
||||
tap-creator
|
||||
model/tap-creator.cc
|
||||
model/tap-encode-decode.cc
|
||||
)
|
||||
set_runtime_outputdirectory(
|
||||
tap-creator
|
||||
${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/src/tap-bridge/
|
||||
""
|
||||
)
|
||||
|
||||
@@ -1,38 +1,44 @@
|
||||
if(${ENABLE_TAP})
|
||||
set(name tap-csma)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libtap-bridge} ${libinternet} ${libwifi})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tap-csma
|
||||
SOURCE_FILES tap-csma.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libtap-bridge}
|
||||
${libinternet}
|
||||
${libwifi}
|
||||
)
|
||||
|
||||
set(name tap-csma-virtual-machine)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libtap-bridge} ${libinternet})
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tap-csma-virtual-machine
|
||||
SOURCE_FILES tap-csma-virtual-machine.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libtap-bridge}
|
||||
${libinternet}
|
||||
)
|
||||
|
||||
set(name tap-wifi-virtual-machine)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libcsma} ${libtap-bridge} ${libinternet} ${libwifi}
|
||||
${libmobility}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tap-wifi-virtual-machine
|
||||
SOURCE_FILES tap-wifi-virtual-machine.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libcsma}
|
||||
${libtap-bridge}
|
||||
${libinternet}
|
||||
${libwifi}
|
||||
${libmobility}
|
||||
)
|
||||
|
||||
set(name tap-wifi-dumbbell)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libwifi} ${libcsma} ${libpoint-to-point}
|
||||
${libtap-bridge} ${libinternet} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME tap-wifi-dumbbell
|
||||
SOURCE_FILES tap-wifi-dumbbell.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libwifi}
|
||||
${libcsma}
|
||||
${libpoint-to-point}
|
||||
${libtap-bridge}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
endif()
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
set(name test)
|
||||
set(name
|
||||
test
|
||||
)
|
||||
|
||||
set(dsr_sources)
|
||||
|
||||
@@ -13,8 +15,14 @@ endif()
|
||||
set(application_sources)
|
||||
set(csma_sources)
|
||||
set(wifi_sources)
|
||||
if(applications IN_LIST ns3-all-enabled-modules)
|
||||
if(point-to-point IN_LIST ns3-all-enabled-modules)
|
||||
if(applications
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
if(point-to-point
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
# cmake-format: off
|
||||
set(applications_sources
|
||||
ns3tcp/ns3tcp-loss-test-suite.cc
|
||||
@@ -24,32 +32,56 @@ if(applications IN_LIST ns3-all-enabled-modules)
|
||||
)
|
||||
# cmake-format: on
|
||||
endif()
|
||||
if(wifi IN_LIST ns3-all-enabled-modules)
|
||||
if(wifi
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
set(wifi_sources
|
||||
ns3wifi/wifi-issue-211-test-suite.cc
|
||||
ns3wifi/wifi-ac-mapping-test-suite.cc
|
||||
ns3wifi/wifi-msdu-aggregator-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
if((csma-layout IN_LIST ns3-all-enabled-modules)
|
||||
AND (internet-apps IN_LIST ns3-all-enabled-modules)
|
||||
if((csma-layout
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
AND (internet-apps
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
)
|
||||
set(csma_sources csma-system-test-suite.cc)
|
||||
set(csma_sources
|
||||
csma-system-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
set(internet_sources)
|
||||
if(internet IN_LIST ns3-all-enabled-modules)
|
||||
set(internet_sources ns3tcp/ns3tcp-socket-writer.cc)
|
||||
if(internet
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
set(internet_sources
|
||||
ns3tcp/ns3tcp-socket-writer.cc
|
||||
)
|
||||
endif()
|
||||
|
||||
set(network_sources)
|
||||
if(network IN_LIST ns3-all-enabled-modules)
|
||||
set(network_sources traced/traced-value-callback-typedef-test-suite.cc)
|
||||
if(network
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
set(network_sources
|
||||
traced/traced-value-callback-typedef-test-suite.cc
|
||||
)
|
||||
endif()
|
||||
|
||||
set(traffic-control_sources)
|
||||
if(traffic-control IN_LIST ns3-all-enabled-modules)
|
||||
if(traffic-control
|
||||
IN_LIST
|
||||
ns3-all-enabled-modules
|
||||
)
|
||||
set(traffic-control_sources
|
||||
ns3tc/fq-cobalt-queue-disc-test-suite.cc
|
||||
ns3tc/fq-codel-queue-disc-test-suite.cc
|
||||
@@ -59,7 +91,8 @@ if(traffic-control IN_LIST ns3-all-enabled-modules)
|
||||
endif()
|
||||
|
||||
add_library(
|
||||
${lib${name}} OBJECT
|
||||
${lib${name}}
|
||||
OBJECT
|
||||
${PROJECT_SOURCE_DIR}/buildsupport/empty.cc # empty source file if only
|
||||
# libcore is enabled
|
||||
${applications_sources}
|
||||
@@ -71,4 +104,7 @@ add_library(
|
||||
${wifi_sources}
|
||||
)
|
||||
|
||||
add_dependencies(${libtest} copy_all_headers)
|
||||
add_dependencies(
|
||||
${libtest}
|
||||
copy_all_headers
|
||||
)
|
||||
|
||||
@@ -1,21 +1,18 @@
|
||||
set(name topology-read)
|
||||
|
||||
set(source_files
|
||||
helper/topology-reader-helper.cc model/inet-topology-reader.cc
|
||||
model/orbis-topology-reader.cc model/rocketfuel-topology-reader.cc
|
||||
build_lib(
|
||||
LIBNAME topology-read
|
||||
SOURCE_FILES
|
||||
helper/topology-reader-helper.cc
|
||||
model/inet-topology-reader.cc
|
||||
model/orbis-topology-reader.cc
|
||||
model/rocketfuel-topology-reader.cc
|
||||
model/topology-reader.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
helper/topology-reader-helper.h model/inet-topology-reader.h
|
||||
model/orbis-topology-reader.h model/rocketfuel-topology-reader.h
|
||||
HEADER_FILES
|
||||
helper/topology-reader-helper.h
|
||||
model/inet-topology-reader.h
|
||||
model/orbis-topology-reader.h
|
||||
model/rocketfuel-topology-reader.h
|
||||
model/topology-reader.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${PCRE_LIBRARIES})
|
||||
|
||||
set(test_sources test/rocketfuel-topology-reader-test-suite.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
${PCRE_LIBRARIES}
|
||||
TEST_SOURCES test/rocketfuel-topology-reader-test-suite.cc
|
||||
)
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
if(PCRE_FOUND)
|
||||
set(name topology-example-sim)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
${libtopology-read} ${libinternet} ${libnix-vector-routing}
|
||||
${libpoint-to-point} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME topology-example-sim
|
||||
SOURCE_FILES topology-example-sim.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libtopology-read}
|
||||
${libinternet}
|
||||
${libnix-vector-routing}
|
||||
${libpoint-to-point}
|
||||
${libapplications}
|
||||
)
|
||||
endif()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name traffic-control)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME traffic-control
|
||||
SOURCE_FILES
|
||||
helper/queue-disc-container.cc
|
||||
helper/traffic-control-helper.cc
|
||||
model/cobalt-queue-disc.cc
|
||||
@@ -18,9 +18,7 @@ set(source_files
|
||||
model/red-queue-disc.cc
|
||||
model/tbf-queue-disc.cc
|
||||
model/traffic-control-layer.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/queue-disc-container.h
|
||||
helper/traffic-control-helper.h
|
||||
model/cobalt-queue-disc.h
|
||||
@@ -38,11 +36,11 @@ set(header_files
|
||||
model/red-queue-disc.h
|
||||
model/tbf-queue-disc.h
|
||||
model/traffic-control-layer.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${libcore} ${libconfig-store})
|
||||
|
||||
set(test_sources
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libcore}
|
||||
${libconfig-store}
|
||||
TEST_SOURCES
|
||||
test/adaptive-red-queue-disc-test-suite.cc
|
||||
test/cobalt-queue-disc-test-suite.cc
|
||||
test/codel-queue-disc-test-suite.cc
|
||||
@@ -54,7 +52,3 @@ set(test_sources
|
||||
test/tbf-queue-disc-test-suite.cc
|
||||
test/tc-flow-control-test-suite.cc
|
||||
)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
)
|
||||
|
||||
@@ -1,80 +1,88 @@
|
||||
set(name red-tests)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libflow-monitor} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME red-tests
|
||||
SOURCE_FILES red-tests.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name red-vs-ared)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libpoint-to-point-layout}
|
||||
${libinternet} ${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME red-vs-ared
|
||||
SOURCE_FILES red-vs-ared.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libpoint-to-point-layout}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name adaptive-red-tests)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libflow-monitor} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME adaptive-red-tests
|
||||
SOURCE_FILES adaptive-red-tests.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name pfifo-vs-red)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libpoint-to-point-layout}
|
||||
${libinternet} ${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME pfifo-vs-red
|
||||
SOURCE_FILES pfifo-vs-red.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libpoint-to-point-layout}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name codel-vs-pfifo-basic-test)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libnetwork} ${libinternet}
|
||||
${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME codel-vs-pfifo-basic-test
|
||||
SOURCE_FILES codel-vs-pfifo-basic-test.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name codel-vs-pfifo-asymmetric)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libnetwork} ${libinternet}
|
||||
${libapplications} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME codel-vs-pfifo-asymmetric
|
||||
SOURCE_FILES codel-vs-pfifo-asymmetric.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libnetwork}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name pie-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libpoint-to-point} ${libinternet} ${libapplications}
|
||||
${libflow-monitor} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME pie-example
|
||||
SOURCE_FILES pie-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
set(name fqcodel-l4s-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link
|
||||
${libpoint-to-point} ${libinternet} ${libinternet-apps} ${libapplications}
|
||||
${libflow-monitor} ${libtraffic-control}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME fqcodel-l4s-example
|
||||
SOURCE_FILES fqcodel-l4s-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libinternet-apps}
|
||||
${libapplications}
|
||||
${libflow-monitor}
|
||||
${libtraffic-control}
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
set(name uan)
|
||||
|
||||
set(source_files
|
||||
build_lib(
|
||||
LIBNAME uan
|
||||
SOURCE_FILES
|
||||
helper/acoustic-modem-energy-model-helper.cc
|
||||
helper/uan-helper.cc
|
||||
model/acoustic-modem-energy-model.cc
|
||||
@@ -24,9 +24,7 @@ set(source_files
|
||||
model/uan-transducer-hd.cc
|
||||
model/uan-transducer.cc
|
||||
model/uan-tx-mode.cc
|
||||
)
|
||||
|
||||
set(header_files
|
||||
HEADER_FILES
|
||||
helper/acoustic-modem-energy-model-helper.h
|
||||
helper/uan-helper.h
|
||||
model/acoustic-modem-energy-model.h
|
||||
@@ -50,12 +48,10 @@ set(header_files
|
||||
model/uan-transducer-hd.h
|
||||
model/uan-transducer.h
|
||||
model/uan-tx-mode.h
|
||||
)
|
||||
|
||||
set(libraries_to_link ${libnetwork} ${libmobility} ${libenergy})
|
||||
|
||||
set(test_sources test/uan-energy-model-test.cc test/uan-test.cc)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
LIBRARIES_TO_LINK
|
||||
${libnetwork}
|
||||
${libmobility}
|
||||
${libenergy}
|
||||
TEST_SOURCES test/uan-energy-model-test.cc
|
||||
test/uan-test.cc
|
||||
)
|
||||
|
||||
@@ -1,49 +1,33 @@
|
||||
set(name uan-cw-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libmobility} ${libstats}
|
||||
${libapplications} ${libuan}
|
||||
set(base_examples
|
||||
uan-cw-example
|
||||
uan-rc-example
|
||||
uan-ipv4-example
|
||||
uan-raw-example
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
foreach(
|
||||
example
|
||||
${base_examples}
|
||||
)
|
||||
build_lib_example(
|
||||
NAME ${example}
|
||||
SOURCE_FILES ${example}.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libmobility}
|
||||
${libstats}
|
||||
${libapplications}
|
||||
${libuan}
|
||||
)
|
||||
endforeach()
|
||||
|
||||
set(name uan-rc-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libmobility} ${libstats}
|
||||
${libapplications} ${libuan}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name uan-6lowpan-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libmobility} ${libstats}
|
||||
${libapplications} ${libuan} ${libsixlowpan}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name uan-ipv4-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libmobility} ${libstats}
|
||||
${libapplications} ${libuan}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
)
|
||||
|
||||
set(name uan-raw-example)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libinternet} ${libmobility} ${libstats}
|
||||
${libapplications} ${libuan}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME uan-6lowpan-example
|
||||
SOURCE_FILES uan-6lowpan-example.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libinternet}
|
||||
${libmobility}
|
||||
${libstats}
|
||||
${libapplications}
|
||||
${libuan}
|
||||
${libsixlowpan}
|
||||
)
|
||||
|
||||
@@ -1,13 +1,6 @@
|
||||
set(name virtual-net-device)
|
||||
|
||||
set(source_files model/virtual-net-device.cc)
|
||||
|
||||
set(header_files model/virtual-net-device.h)
|
||||
|
||||
set(libraries_to_link ${libnetwork})
|
||||
|
||||
set(test_sources)
|
||||
|
||||
build_lib("${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
"${test_sources}"
|
||||
build_lib(
|
||||
LIBNAME virtual-net-device
|
||||
SOURCE_FILES model/virtual-net-device.cc
|
||||
HEADER_FILES model/virtual-net-device.h
|
||||
LIBRARIES_TO_LINK ${libnetwork}
|
||||
)
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
set(name virtual-net-device)
|
||||
set(source_files ${name}.cc)
|
||||
set(header_files)
|
||||
set(libraries_to_link ${libvirtual-net-device} ${libpoint-to-point}
|
||||
${libinternet} ${libapplications}
|
||||
)
|
||||
build_lib_example(
|
||||
"${name}" "${source_files}" "${header_files}" "${libraries_to_link}"
|
||||
NAME virtual-net-device
|
||||
SOURCE_FILES virtual-net-device.cc
|
||||
LIBRARIES_TO_LINK
|
||||
${libvirtual-net-device}
|
||||
${libpoint-to-point}
|
||||
${libinternet}
|
||||
${libapplications}
|
||||
)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user