mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-15 11:53:49 +07:00
Darwin arm64: Fix MacLauncher compiler warnings
GitOrigin-RevId: e5e728b584e39be59b15dc24145c1d911f00f6a8
This commit is contained in:
committed by
intellij-monorepo-bot
parent
9bddc1bd50
commit
767c637715
1
native/MacLauncher/.idea/.name
generated
1
native/MacLauncher/.idea/.name
generated
@@ -1 +0,0 @@
|
||||
MacLauncher
|
||||
11
native/MacLauncher/.idea/AppLauncher.iml
generated
11
native/MacLauncher/.idea/AppLauncher.iml
generated
@@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="CIDR_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<sourceFolder url="file://$MODULE_DIR$" isTestSource="false" />
|
||||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
|
||||
3
native/MacLauncher/.idea/dictionaries/max.xml
generated
3
native/MacLauncher/.idea/dictionaries/max.xml
generated
@@ -1,3 +0,0 @@
|
||||
<component name="ProjectDictionaryState">
|
||||
<dictionary name="max" />
|
||||
</component>
|
||||
5
native/MacLauncher/.idea/encodings.xml
generated
5
native/MacLauncher/.idea/encodings.xml
generated
@@ -1,5 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
|
||||
</project>
|
||||
|
||||
5
native/MacLauncher/.idea/find.xml
generated
5
native/MacLauncher/.idea/find.xml
generated
@@ -1,5 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="OCFindUsagesOptions" text="true" ivars="false" properties="true" derivedClasses="false" />
|
||||
</project>
|
||||
|
||||
8
native/MacLauncher/.idea/misc.xml
generated
8
native/MacLauncher/.idea/misc.xml
generated
@@ -1,8 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectResources">
|
||||
<default-html-doctype>http://www.w3.org/1999/xhtml</default-html-doctype>
|
||||
</component>
|
||||
<component name="ProjectRootManager" version="2" />
|
||||
</project>
|
||||
|
||||
9
native/MacLauncher/.idea/modules.xml
generated
9
native/MacLauncher/.idea/modules.xml
generated
@@ -1,9 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/AppLauncher.iml" filepath="$PROJECT_DIR$/.idea/AppLauncher.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
<component name="DependencyValidationManager">
|
||||
<state>
|
||||
<option name="SKIP_IMPORT_STATEMENTS" value="false" />
|
||||
</state>
|
||||
</component>
|
||||
7
native/MacLauncher/.idea/vcs.xml
generated
7
native/MacLauncher/.idea/vcs.xml
generated
@@ -1,7 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="VcsDirectoryMappings">
|
||||
<mapping directory="$PROJECT_DIR$/../.." vcs="Git" />
|
||||
</component>
|
||||
</project>
|
||||
|
||||
5
native/MacLauncher/.idea/xcode.xml
generated
5
native/MacLauncher/.idea/xcode.xml
generated
@@ -1,5 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="XcodeMetaData" PROJECT_FILE="$PROJECT_DIR$/MacLauncher.xcodeproj" />
|
||||
</project>
|
||||
|
||||
@@ -18,4 +18,13 @@
|
||||
BOOL validationJavaVersion();
|
||||
|
||||
- (void) launch;
|
||||
@end
|
||||
@end
|
||||
|
||||
NSString *getExecutable();
|
||||
NSString *jvmVersion(NSBundle *bundle);
|
||||
NSString *requiredJvmVersions();
|
||||
NSString *getPropertiesFilePath();
|
||||
NSString *getPreferencesFolderPath();
|
||||
BOOL meetMinRequirements(NSString *vmVersion);
|
||||
BOOL satisfies(NSString *vmVersion, NSString *requiredVersion);
|
||||
typedef jint (JNICALL *fun_ptr_t_CreateJavaVM)(JavaVM **pvm, JNIEnv **env, void *args);
|
||||
|
||||
@@ -10,16 +10,11 @@
|
||||
#import "PropertyFileReader.h"
|
||||
#import "utils.h"
|
||||
#import <dlfcn.h>
|
||||
@class NSAlert;
|
||||
|
||||
typedef jint (JNICALL *fun_ptr_t_CreateJavaVM)(JavaVM **pvm, void **env, void *args);
|
||||
NSBundle *vm;
|
||||
NSString *const JVMOptions = @"JVMOptions";
|
||||
NSString *JVMVersion = NULL;
|
||||
NSString* minRequiredJavaVersion = @"1.8";
|
||||
NSString* osxVersion = @"10.10";
|
||||
BOOL javaUpdateRequired = false;
|
||||
|
||||
|
||||
@interface NSString (CustomReplacements)
|
||||
- (NSString *)replaceAll:(NSString *)pattern to:(NSString *)replacement;
|
||||
@@ -70,14 +65,6 @@ BOOL javaUpdateRequired = false;
|
||||
return self;
|
||||
}
|
||||
|
||||
NSString* getOSXVersion(){
|
||||
NSString *versionString;
|
||||
NSDictionary * sv = [NSDictionary dictionaryWithContentsOfFile:@"/System/Library/CoreServices/SystemVersion.plist"];
|
||||
versionString = [sv objectForKey:@"ProductVersion"];
|
||||
//NSLog(@"OS X: %@", versionString);
|
||||
return versionString;
|
||||
}
|
||||
|
||||
void showWarning(NSString* messageText){
|
||||
NSAlert* alert = [[NSAlert alloc] init];
|
||||
[alert addButtonWithTitle:@"OK"];
|
||||
@@ -85,7 +72,7 @@ void showWarning(NSString* messageText){
|
||||
NSString* informativeText =[NSString stringWithFormat:@"%@",message_description];
|
||||
[alert setMessageText:messageText];
|
||||
[alert setInformativeText:informativeText ];
|
||||
[alert setAlertStyle:NSWarningAlertStyle];
|
||||
[alert setAlertStyle:NSAlertStyleWarning];
|
||||
[alert runModal];
|
||||
[alert release];
|
||||
}
|
||||
@@ -181,7 +168,7 @@ BOOL satisfies(NSString *vmVersion, NSString *requiredVersion) {
|
||||
return [vmVersion hasPrefix:requiredVersion];
|
||||
}
|
||||
|
||||
NSComparisonResult compareVMVersions(id vm1, id vm2, void *context) {
|
||||
NSComparisonResult compareVMVersions(id vm1, id vm2, __unused void *context) {
|
||||
return [jvmVersion(vm2) compare:jvmVersion(vm1) options:NSNumericSearch];
|
||||
}
|
||||
|
||||
@@ -319,10 +306,6 @@ NSString *getExecutable() {
|
||||
return getJVMProperty(@"idea.executable");
|
||||
}
|
||||
|
||||
NSString *getBundleName() {
|
||||
return [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleName"];
|
||||
}
|
||||
|
||||
NSString *getPropertiesFilePath() {
|
||||
return [getPreferencesFolderPath() stringByAppendingString:@"/idea.properties"];
|
||||
}
|
||||
@@ -479,25 +462,6 @@ BOOL validationJavaVersion(){
|
||||
return true;
|
||||
}
|
||||
|
||||
- (void)alert:(NSArray *)values {
|
||||
NSAlert *alert = [[[NSAlert alloc] init] autorelease];
|
||||
[alert setMessageText:[values objectAtIndex:0]];
|
||||
[alert setInformativeText:[values objectAtIndex:1]];
|
||||
|
||||
if ([values count] > 2) {
|
||||
NSTextView *accessory = [[NSTextView alloc] initWithFrame:NSMakeRect(0, 0 , 300 , 15)];
|
||||
[accessory setFont:[NSFont systemFontOfSize:[NSFont smallSystemFontSize]]];
|
||||
NSMutableAttributedString *str = [[NSMutableAttributedString alloc] initWithString: [values objectAtIndex:2]];
|
||||
[str addAttribute: NSLinkAttributeName value: [values objectAtIndex:2] range: NSMakeRange(0, str.length)];
|
||||
[accessory insertText:str];
|
||||
[accessory setEditable:NO];
|
||||
[accessory setDrawsBackground:NO];
|
||||
[alert setAccessoryView:accessory];
|
||||
}
|
||||
|
||||
[alert runModal];
|
||||
}
|
||||
|
||||
- (void)launch {
|
||||
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
|
||||
|
||||
@@ -558,7 +522,7 @@ BOOL validationJavaVersion(){
|
||||
create_vm_rc = create_vm(&jvm, &env, &args);
|
||||
}
|
||||
if (create_vm == NULL || create_vm_rc != JNI_OK) {
|
||||
NSLog(@"JNI_CreateJavaVM (%@) failed: %ld", vm.bundlePath, create_vm_rc);
|
||||
NSLog(@"JNI_CreateJavaVM (%@) failed: %d", vm.bundlePath, create_vm_rc);
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -201,7 +201,7 @@
|
||||
GCC_WARN_ABOUT_RETURN_TYPE = YES;
|
||||
GCC_WARN_UNINITIALIZED_AUTOS = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.9;
|
||||
SDKROOT = macosx;
|
||||
};
|
||||
name = Release;
|
||||
@@ -228,7 +228,7 @@
|
||||
GCC_WARN_ABOUT_RETURN_TYPE = YES;
|
||||
GCC_WARN_UNINITIALIZED_AUTOS = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.8;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.9;
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
SDKROOT = macosx;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user