Skip to content

Commit

Permalink
Build with MacPorts Xlib if present
Browse files Browse the repository at this point in the history
and prefer MacPorts over XQuartz and regular OS X versions which
are rather old. (Even older than the latest xorg security errata.)
  • Loading branch information
jpouellet authored and fikovnik committed Apr 27, 2015
1 parent fa9e7be commit 9807e69
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
12 changes: 8 additions & 4 deletions ShiftIt/ShiftIt.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1010,13 +1010,15 @@
GCC_PREFIX_HEADER = ShiftIt_Prefix.pch;
GCC_PREPROCESSOR_DEFINITIONS_NOT_USED_IN_PRECOMPS = "_DEBUGPRINTS_=1";
HEADER_SEARCH_PATHS = (
/usr/X11/include,
/opt/local/include,
/opt/X11/include,
/usr/X11/include,
);
INFOPLIST_FILE = "ShiftIt-Info.plist";
LIBRARY_SEARCH_PATHS = (
/usr/X11/lib,
/opt/local/lib,
/opt/X11/lib,
/usr/X11/lib,
);
OTHER_CFLAGS = (
"-DDEBUG",
Expand All @@ -1035,13 +1037,15 @@
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = ShiftIt_Prefix.pch;
HEADER_SEARCH_PATHS = (
/usr/X11/include,
/opt/local/include,
/opt/X11/include,
/usr/X11/include,
);
INFOPLIST_FILE = "ShiftIt-Info.plist";
LIBRARY_SEARCH_PATHS = (
/usr/X11/lib,
/opt/local/lib,
/opt/X11/lib,
/usr/X11/lib,
);
OTHER_CFLAGS = (
"-DNDEBUG",
Expand Down
6 changes: 3 additions & 3 deletions ShiftIt/X11WindowDriver.m
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ - (BOOL)getGeometry:(NSRect *)geometry screen:(SIScreen **)screenRef error:(NSEr
*screenRef = screen;
}
}

return ret;
}

Expand Down Expand Up @@ -425,7 +425,7 @@ - (BOOL)setGeometry_:(NSRect)geometry ofWindow:(Window *)windowRef error:(NSErro
FMTAssertNotNil(windowRef);

return execWithDisplay_(^BOOL(Display *dpy, NSError **nestedError) {
// TODO: combine the operations
// TODO: combine the operations
XWindowAttributes wa;
if(!XGetWindowAttributesRef(dpy, *windowRef, &wa)) {
if (nestedError) {
Expand Down Expand Up @@ -463,4 +463,4 @@ - (void) freeWindow_:(Window *)windowRef {
}


@end
@end

0 comments on commit 9807e69

Please sign in to comment.