mirror of
https://github.com/zhigang1992/RubyMotion.git
synced 2026-04-29 05:05:37 +08:00
define RUBYMOTION_VERSION
This commit is contained in:
@@ -245,7 +245,7 @@ EOS
|
||||
#import <UIKit/UIKit.h>
|
||||
|
||||
extern "C" {
|
||||
void rb_define_const(void *, const char *, void *);
|
||||
void rb_define_global_const(const char *, void *);
|
||||
void rb_rb2oc_exc_handler(void);
|
||||
void rb_exit(int);
|
||||
void RubyMotionInit(int argc, char **argv);
|
||||
@@ -334,7 +334,8 @@ EOS
|
||||
else
|
||||
config.development? ? 'development' : 'release'
|
||||
end
|
||||
main_txt << "rb_define_const([NSObject class], \"RUBYMOTION_ENV\", @\"#{rubymotion_env}\");\n"
|
||||
main_txt << "rb_define_global_const(\"RUBYMOTION_ENV\", @\"#{rubymotion_env}\");\n"
|
||||
main_txt << "rb_define_global_const(\"RUBYMOTION_VERSION\", @\"#{Motion::Version}\");\n"
|
||||
main_txt << <<EOS
|
||||
retval = UIApplicationMain(argc, argv, nil, @"#{config.delegate_class}");
|
||||
rb_exit(retval);
|
||||
|
||||
Reference in New Issue
Block a user