Skip to content

Commit 96cafb0

Browse files
committed
Revert "Implement Semaphore CarbonCore Stubs"
This reverts commit 882fec3.
1 parent f3b0ae0 commit 96cafb0

File tree

2 files changed

+1
-37
lines changed

2 files changed

+1
-37
lines changed

src/frameworks/CoreServices/include/CarbonCore/Multiprocessing.h

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ enum {
1414
};
1515

1616
typedef void* MPCriticalRegionID;
17-
typedef struct OpaqueMPSemaphoreID *MPSemaphoreID;
18-
typedef ItemCount MPSemaphoreCount;
1917

2018
Boolean _MPIsFullyInitialized();
2119
OSStatus MPDelayUntil(AbsoluteTime* time);
@@ -25,10 +23,7 @@ OSStatus MPCreateCriticalRegion(MPCriticalRegionID* criticalRegion);
2523
OSStatus MPDeleteCriticalRegion(MPCriticalRegionID criticalRegion);
2624
OSStatus MPEnterCriticalRegion(MPCriticalRegionID criticalRegion, Duration timeout);
2725
OSStatus MPExitCriticalRegion(MPCriticalRegionID criticalRegion);
28-
OSStatus MPCreateSemaphore(MPSemaphoreCount maximumValue, MPSemaphoreCount initialValue, MPSemaphoreID *semaphore);
29-
OSStatus MPDeleteSemaphore(MPSemaphoreID semaphore);
30-
OSStatus MPSignalSemaphore(MPSemaphoreID semaphore);
31-
OSStatus MPWaitOnSemaphore(MPSemaphoreID semaphore, Duration timeout);
26+
3227
// other functions are missing...
3328

3429
#ifdef __cplusplus

src/frameworks/CoreServices/src/CarbonCore/Multiprocessing.cpp

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,8 @@ along with Darling. If not, see <http://www.gnu.org/licenses/>.
2121
#include <unistd.h>
2222
#include <ctime>
2323
#include <pthread.h>
24-
#include <stdio.h>
25-
#include <stdlib.h>
2624
#include <CarbonCore/MacErrors.h>
2725

28-
static int verbose = 0;
29-
__attribute__((constructor)) static void initme(void) {
30-
verbose = getenv("STUB_VERBOSE") != NULL;
31-
}
32-
3326
Boolean _MPIsFullyInitialized()
3427
{
3528
return true;
@@ -116,27 +109,3 @@ OSStatus MPExitCriticalRegion(MPCriticalRegionID criticalRegion)
116109
else
117110
return paramErr;
118111
}
119-
120-
OSStatus MPCreateSemaphore(MPSemaphoreCount maximumValue, MPSemaphoreCount initialValue, MPSemaphoreID *semaphore)
121-
{
122-
if (verbose) puts("STUB: MPCreateSemaphore called");
123-
return noErr;
124-
}
125-
126-
OSStatus MPDeleteSemaphore(MPSemaphoreID semaphore)
127-
{
128-
if (verbose) puts("STUB: MPDeleteSemaphore called");
129-
return noErr;
130-
}
131-
132-
OSStatus MPSignalSemaphore(MPSemaphoreID semaphore)
133-
{
134-
if (verbose) puts("STUB: MPSignalSemaphore called");
135-
return noErr;
136-
}
137-
138-
OSStatus MPWaitOnSemaphore(MPSemaphoreID semaphore, Duration timeout)
139-
{
140-
if (verbose) puts("STUB: MPWaitOnSemaphore called");
141-
return noErr;
142-
}

0 commit comments

Comments
 (0)