@@ -345,20 +345,15 @@ if(HAVE_UNISTD_H)
345345endif ()
346346
347347
348- # Check for missing functions: fgetln(3) is in 4.4BSD; mkstemp (3) is
349- # in 4.3BSD , POSIX.1-2001; realpath (3) is in 4.4BSD, POSIX.1-2001;
350- # regex(3) is in POSIX.1-2001, POSIX.1-2008.
348+ # Check for missing functions: fgetln(3) is in 4.4BSD; realpath (3) is
349+ # in 4.4BSD , POSIX.1-2001; regcomp (3) is in POSIX.1-2001,
350+ # POSIX.1-2008.
351351include (CheckSymbolExists )
352352check_symbol_exists (fgetln "stdio.h" HAVE_FGETLN )
353353if (HAVE_FGETLN)
354354 add_compile_definitions ("HAVE_FGETLN" )
355355endif ()
356356
357- check_symbol_exists (mkstemp "stdlib.h" HAVE_MKSTEMP )
358- if (HAVE_MKSTEMP)
359- add_compile_definitions ("HAVE_MKSTEMP" )
360- endif ()
361-
362357check_symbol_exists (realpath "stdlib.h" HAVE_REALPATH )
363358if (HAVE_REALPATH)
364359 add_compile_definitions ("HAVE_REALPATH" )
@@ -1121,10 +1116,6 @@ add_executable(cbf2nexus
11211116 "${CBF__EXAMPLES} /cbf2nexus.c" )
11221117target_link_libraries (cbf2nexus
11231118 cbf )
1124- if (NOT HAVE_MKSTEMP)
1125- target_sources (cbf2nexus
1126- PRIVATE "${CBF__SRC} /mkstemp.c" )
1127- endif ()
11281119
11291120add_executable (nexus2cbf
11301121 "${CBF__EXAMPLES} /nexus2cbf.c" )
@@ -1136,10 +1127,6 @@ add_executable(minicbf2nexus
11361127 "${CBF__EXAMPLES} /minicbf2nexus.c" )
11371128target_link_libraries (minicbf2nexus
11381129 cbf )
1139- if (NOT HAVE_MKSTEMP)
1140- target_sources (minicbf2nexus
1141- PRIVATE "${CBF__SRC} /mkstemp.c" )
1142- endif ()
11431130
11441131add_executable (adscimg2cbf
11451132 "${CBF__EXAMPLES} /adscimg2cbf.c"
@@ -1162,19 +1149,11 @@ add_executable(convert_image
11621149 "${CBF__EXAMPLES} /convert_image.c" )
11631150target_link_libraries (convert_image
11641151 cbf )
1165- if (NOT HAVE_MKSTEMP)
1166- target_sources (convert_image
1167- PRIVATE "${CBF__SRC} /mkstemp.c" )
1168- endif ()
11691152
11701153add_executable (convert_minicbf
11711154 "${CBF__EXAMPLES} /convert_minicbf.c" )
11721155target_link_libraries (convert_minicbf
11731156 cbf )
1174- if (NOT HAVE_MKSTEMP)
1175- target_sources (convert_minicbf
1176- PRIVATE "${CBF__SRC} /mkstemp.c" )
1177- endif ()
11781157
11791158add_executable (makecbf
11801159 "${CBF__EXAMPLES} /makecbf.c" )
@@ -1211,30 +1190,13 @@ add_executable(img2cif
12111190 "${CBF__EXAMPLES} /img2cif.c" )
12121191target_link_libraries (img2cif
12131192 cbf )
1214- if (NOT HAVE_MKSTEMP)
1215- target_sources (img2cif
1216- PRIVATE "${CBF__SRC} /mkstemp.c" )
1217- endif ()
1218-
1219- add_executable (cif2c
1220- "${CBF__EXAMPLES} /cif2c.c" )
1221- target_link_libraries (cif2c
1222- cbf )
1223- if (NOT HAVE_MKSTEMP)
1224- target_sources (cif2c
1225- PRIVATE "${CBF__SRC} /mkstemp.c" )
1226- endif ()
12271193
12281194add_executable (cif2cbf
12291195 "${CBF__EXAMPLES} /cif2cbf.c" )
12301196target_link_libraries (cif2cbf
12311197 cbf
12321198 CQR
12331199 "${libm} " )
1234- if (NOT HAVE_MKSTEMP)
1235- target_sources (cif2cbf
1236- PRIVATE "${CBF__SRC} /mkstemp.c" )
1237- endif ()
12381200
12391201add_executable (cbf_template_t
12401202 "${CBF__DECTRIS_EXAMPLES} /cbf_template_t.c" )
@@ -1262,10 +1224,6 @@ add_executable(sequence_match
12621224 "${CBF__EXAMPLES} /sequence_match.c" )
12631225target_link_libraries (sequence_match
12641226 cbf )
1265- if (NOT HAVE_MKSTEMP)
1266- target_sources (sequence_match
1267- PRIVATE "${CBF__SRC} /mkstemp.c" )
1268- endif ()
12691227
12701228add_executable (test_cbf_airy_disk
12711229 "${CBF__EXAMPLES} /test_cbf_airy_disk.c" )
0 commit comments