Skip to content

Commit b92ed9e

Browse files
authored
Remove exclusions for the deleted ofAppGlutWindow (non-Linux) (#8665)
* Remove exclusions for the deleted ofAppGlutWindow (macOS, iOS, emscripten, qbs) * networkTcp test: retry with another port on EADDRINUSE
1 parent 4e987b7 commit b92ed9e

9 files changed

Lines changed: 21 additions & 16 deletions

File tree

‎libs/openFrameworksCompiled/project/CMake/platform/emscripten.cmake‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ set(OF_PLATFORM_CORE_EXCLUDES
5353
"/sound/ofFmodSoundPlayer\\.cpp$"
5454
"/sound/ofOpenALSoundPlayer\\.cpp$"
5555
"/sound/ofRtAudioSoundStream\\.cpp$"
56-
"/app/ofAppGlutWindow\\.cpp$"
5756
"/app/ofAppGLFWWindow\\.cpp$"
5857
"/app/ofAppEGLWindow\\.cpp$")
5958

‎libs/openFrameworksCompiled/project/CMake/platform/ios.cmake‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ of_dir_and_subdirs(OF_PLATFORM_INCLUDE_DIRS "${OF_ADDONS_DIR}/ofxiOS/src")
5656
set(OF_PLATFORM_CORE_EXCLUDES
5757
"/libs/openFrameworks/app/ofAppGLFWWindow\\.cpp$"
5858
"/libs/openFrameworks/app/ofAppEGLWindow\\.cpp$"
59-
"/libs/openFrameworks/app/ofAppGlutWindow\\.cpp$"
6059
"/libs/openFrameworks/app/ofAppNoWindow\\.cpp$"
6160
"/libs/openFrameworks/communication/"
6261
"/libs/openFrameworks/graphics/ofCairoRenderer\\.cpp$"

‎libs/openFrameworksCompiled/project/CMake/platform/macos.cmake‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ endif()
1111
set(OF_PLATFORM_SOURCE_EXTENSIONS cpp cc cxx c mm m)
1212

1313
set(OF_PLATFORM_CORE_EXCLUDES
14-
"/app/ofAppGlutWindow\\.cpp$"
1514
"/app/ofAppEGLWindow\\.cpp$"
1615
"/video/ofDirectShow"
1716
"/video/ofMediaFoundation"

‎libs/openFrameworksCompiled/project/emscripten/CMakeList.txt‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,6 @@ PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/communication/%.cpp
211211
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/sound/ofFmodSoundPlayer.cpp
212212
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/sound/ofOpenALSoundPlayer.cpp
213213
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/sound/ofRtAudioSoundStream.cpp
214-
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppGlutWindow.cpp
215214
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppGLFWWindow.cpp
216215
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppEGLWindow.cpp
217216
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/graphics/ofCairoRenderer.cpp

‎libs/openFrameworksCompiled/project/emscripten/config.emscripten.default.mk‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,6 @@ PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/communication/%.cpp
281281
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/sound/ofFmodSoundPlayer.cpp
282282
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/sound/ofOpenALSoundPlayer.cpp
283283
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/sound/ofRtAudioSoundStream.cpp
284-
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppGlutWindow.cpp
285284
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppGLFWWindow.cpp
286285
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppEGLWindow.cpp
287286
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/graphics/ofCairoRenderer.cpp

‎libs/openFrameworksCompiled/project/macos/config.macos.default.mk‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,6 @@ endif
267267
##########################################################################################
268268

269269
# core sources
270-
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppGlutWindow.cpp
271270
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/video/ofDirectShowGrabber.cpp
272271
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/video/ofDirectShowPlayer.cpp
273272
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/video/ofMediaFoundationPlayer.cpp

‎libs/openFrameworksCompiled/project/osx/config.osx.default.mk‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,6 @@ endif
269269
##########################################################################################
270270

271271
# core sources
272-
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/app/ofAppGlutWindow.cpp
273272
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/video/ofDirectShowGrabber.cpp
274273
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/video/ofDirectShowPlayer.cpp
275274
PLATFORM_CORE_EXCLUSIONS += $(OF_LIBS_PATH)/openFrameworks/video/ofMediaFoundationPlayer.cpp

‎libs/openFrameworksCompiled/project/qtcreator/openFrameworks.qbs‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ Product{
5656
var excludes = [];
5757
if(qbs.targetOS.indexOf("linux")>-1){
5858
excludes = [
59-
"app/ofAppGlutWindow\\..*",
6059
"video/ofDirectShowPlayer\\..*",
6160
"video/ofDirectShowGrabber\\..*",
6261
"video/ofAVFoundationVideoPlayer\\..*",
@@ -69,7 +68,6 @@ Product{
6968
];
7069
}else if(qbs.targetOS.indexOf("windows")>-1){
7170
excludes = [
72-
"app/ofAppGlutWindow\\..*",
7371
"video/ofGstVideoPlayer\\..*",
7472
"video/ofGstVideoGrabber\\..*",
7573
"video/ofGstUtils\\..*",
@@ -83,7 +81,6 @@ Product{
8381
];
8482
}else if(qbs.targetOS.indexOf("osx")>-1){
8583
excludes = [
86-
"app/ofAppGlutWindow.*",
8784
"video/ofGstVideoPlayer\\..*",
8885
"video/ofGstVideoGrabber\\..*",
8986
"video/ofGstUtils\\..*",

‎tests/addons/networkTcp/src/main.cpp‎

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,29 @@
55

66
class ofApp: public ofxUnitTestsApp{
77
public:
8+
// The random port can already be in use on a busy CI runner (EADDRINUSE),
9+
// so retry with a different random port instead of failing the test.
10+
// The chosen port is written back so the client connects to the right one.
11+
static bool setupServer(ofxTCPServer & server, int & port, bool blocking){
12+
for(int attempt = 0; attempt < 20; attempt++){
13+
if(server.setup(port, blocking)){
14+
return true;
15+
}
16+
server.close();
17+
ofLogNotice() << "port " << port << " in use, trying another";
18+
port = ofRandom(15000, 65535);
19+
}
20+
return false;
21+
}
22+
823
void testNonBlocking(int timeout = 0){
924
ofLogNotice() << "---------------------------------------";
1025
ofLogNotice() << "testNonBlocking";
1126

1227
int port = ofRandom(15000, 65535);
1328

1429
ofxTCPServer server;
15-
ofxTest(server.setup(port,false), "non blocking server");
30+
ofxTest(setupServer(server, port, false), "non blocking server");
1631

1732
ofxTCPClient client;
1833
ofxTest(client.setup("127.0.0.1",port,false), "non blocking client");
@@ -64,7 +79,7 @@ class ofApp: public ofxUnitTestsApp{
6479
int port = ofRandom(15000, 65535);
6580

6681
ofxTCPServer server;
67-
ofxTest(server.setup(port,true), "blocking server");
82+
ofxTest(setupServer(server, port, true), "blocking server");
6883

6984
ofxTCPClient client;
7085
ofxTest(client.setup("127.0.0.1",port,true), "blocking client");
@@ -87,7 +102,7 @@ class ofApp: public ofxUnitTestsApp{
87102
int port = ofRandom(15000, 65535);
88103

89104
ofxTCPServer server;
90-
ofxTest(server.setup(port,true), "blocking server");
105+
ofxTest(setupServer(server, port, true), "blocking server");
91106

92107
ofxTCPClient client;
93108
ofxTest(client.setup("127.0.0.1",port,true), "blocking client");
@@ -116,7 +131,7 @@ class ofApp: public ofxUnitTestsApp{
116131
int port = ofRandom(15000, 65535);
117132

118133
ofxTCPServer server;
119-
ofxTest(server.setup(port,true), "blocking server");
134+
ofxTest(setupServer(server, port, true), "blocking server");
120135

121136
ofxTCPClient client;
122137
ofxTest(client.setup("127.0.0.1", port, true), "blocking client");
@@ -151,7 +166,7 @@ class ofApp: public ofxUnitTestsApp{
151166
int port = ofRandom(15000, 65535);
152167

153168
ofxTCPServer server;
154-
ofxTest(server.setup(port,true), "blocking server");
169+
ofxTest(setupServer(server, port, true), "blocking server");
155170

156171
ofxTCPClient client;
157172
ofxTest(client.setup("127.0.0.1", port, true), "blocking client");
@@ -244,7 +259,7 @@ class ofApp: public ofxUnitTestsApp{
244259
int port = ofRandom(15000, 65535);
245260

246261
ofxTCPServer server;
247-
ofxTest(server.setup(port,true), "blocking server");
262+
ofxTest(setupServer(server, port, true), "blocking server");
248263

249264
ofxTCPClient client;
250265
ofxTest(client.setup("127.0.0.1", port, true), "blocking client");

0 commit comments

Comments
 (0)