[Vm-dev] VM Maker: CMakeVMMaker-EstebanLorenzano.182.mcz
commits at source.squeak.org
commits at source.squeak.org
Tue Oct 23 16:43:21 UTC 2012
Esteban Lorenzano uploaded a new version of CMakeVMMaker to project VM Maker:
http://source.squeak.org/VMMaker/CMakeVMMaker-EstebanLorenzano.182.mcz
==================== Summary ====================
Name: CMakeVMMaker-EstebanLorenzano.182
Author: EstebanLorenzano
Time: 23 October 2012, 6:42:53.927 pm
UUID: 7eb37e28-9f77-4c1b-9264-ef66ac71a9c8
Ancestors: CMakeVMMaker-IgorStasenko.181
- added StackSimulatorConfig, runs iStackVM in simulator (thanks Nick!)
- Added Info.plist properties for managing memory and other options
-- added options for Web Mode too
=============== Diff against CMakeVMMaker-IgorStasenko.181 ===============
Item was added:
+ ----- Method: StackIPhoneConfig>>ImageIsScrollable (in category 'bundle strings') -----
+ ImageIsScrollable
+ ^false!
Item was added:
+ ----- Method: StackIPhoneConfig>>ImageIsWritable (in category 'bundle strings') -----
+ ImageIsWritable
+ ^true!
Item was added:
+ ----- Method: StackIPhoneConfig>>VMMemorySize (in category 'bundle strings') -----
+ VMMemorySize
+ ^1024 * 1024 * 64 "64M"!
Item was added:
+ ----- Method: StackIPhoneConfig>>WebViewAsUI (in category 'bundle strings') -----
+ WebViewAsUI
+ ^false!
Item was added:
+ ----- Method: StackIPhoneConfig>>WebViewUrl (in category 'bundle strings') -----
+ WebViewUrl
+ ^'http://localhost:8080'!
Item was changed:
----- Method: StackIPhoneConfig>>architecture (in category 'accessing') -----
architecture
+ ^'armv7'!
- ^'armv6'!
Item was changed:
----- Method: StackIPhoneConfig>>commonCompilerFlags (in category 'settings') -----
commonCompilerFlags
"Common compiler flags"
^{
"'-miphoneos-version-min=4.3'. "
+ '-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/{target}.platform/Developer/SDKs/{target}{sdkVersion}.sdk' nameFormat: { 'target'-> self targetDevice. 'sdkVersion'->self sdkVersion} asDictionary.
- '-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS', self sdkVersion, '.sdk'.
'-x objective-c'.
'-std=gnu99'.
'-falign-functions=16'.
'-fno-gcse'.
'-fno-cse-follow-jumps'.
'-fvisibility=hidden'.
'-funroll-loops'.
'-finline-functions'.
'-mno-thumb'.
'-fwrapv'.
'-DSTACKVM=1'.
'-DCOGMTVM=0'.
'-DUSE_GLOBAL_STRUCT=0'.
'-DBASE_HEADER_SIZE=4'.
'-DTARGET_OS_IS_IPHONE'.
'-DHAVE_UUID_GENERATE'.
"'-DUSE_INLINE_MEMORY_ACCESSORS'. "
'-DHAVE_SYS_TIME_H'.
'-DLSB_FIRST'.
'-DHAVE_NANOSLEEP'.
'-DISQUEAK_IMAGE=', self imageName.
+ '-DISQUEAK_SOURCES=PharoV10'.
+ '-DSTACKVM'}!
- '-DISQUEAK_SOURCES=PharoV10'}!
Item was changed:
----- Method: StackIPhoneConfig>>compilerFlagsRelease (in category 'settings') -----
compilerFlagsRelease
+ ^#('-g0' '-O3' '-fomit-frame-pointer' '-DNDEBUG' '-DDEBUGVM=0')!
- ^#('-g0' '-O3' '-fomit-frame-pointer' '-DNDEBUG' '-DDEBUGVM=0' '-DSTACKVM')!
Item was changed:
----- Method: StackIPhoneConfig>>configureFT2Plugin: (in category 'plugin extra rules') -----
configureFT2Plugin: maker
"extra rules for Freetype plugin.
a custom rule to build freetype library"
| lib devRoot sdkRoot |
"maker isExternal
ifFalse: [ self error: 'building internal FT2Plugin is not supported yet' ]."
+ devRoot := '/Applications/Xcode.app/Contents/Developer/Platforms/{target}.platform/Developer'
+ nameFormat: { 'target'->self targetDevice} asDictionary.
- devRoot := '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer'.
sdkRoot := '{devRoot}/SDKs/iPhoneOS{sdkVersion}.sdk'
nameFormat: {'devRoot'->devRoot. 'sdkVersion'->self sdkVersion} asDictionary.
"add freetype library into loop"
lib := self addThirdpartyLibrary: 'freetype2'.
lib configurationFlags: ({
'--without-zlib'.
'--without-bzip2'.
'--host=arm-apple-darwin'.
'--enable-static=yes'.
'--enable-shared=no'.
'CC={devRoot}/usr/bin/gcc'.
'CXX={devRoot}/usr/bin/g++'.
+ 'CFLAGS=\\"-arch {architecture} -std=c99 -Wno-trigraphs -O2 -fwrapv -Wreturn-type -Wunused-variable -fmessage-length=0 -miphoneos-version-min=4.0 -I{sdkRoot}/usr/include/libxml2 -isysroot {sdkRoot}\\"'.
+ 'LDFLAGS=\\"-arch {architecture} -isysroot {sdkRoot}\\"'}
+ collect: [ :each | each nameFormat: {
+ 'architecture'->self architecture.
+ 'sdkRoot'->sdkRoot.
+ 'devRoot'->devRoot} asDictionary ]).
- 'CFLAGS=\\"-arch armv6 -std=c99 -Wno-trigraphs -O2 -fwrapv -Wreturn-type -Wunused-variable -fmessage-length=0 -miphoneos-version-min=4.0 -I{sdkRoot}/usr/include/libxml2 -isysroot {sdkRoot}\\"'.
- 'LDFLAGS=\\"-arch armv6 -isysroot {sdkRoot}\\"'}
- collect: [ :each | each nameFormat: {'sdkRoot'->sdkRoot. 'devRoot'->devRoot} asDictionary ]).
"maker set: 'XCODE_ATTRIBUTE_CONFIGURATION_BUILD_DIR' toString: ''."
"link plugin with freetype lib"
maker addExternalLibrary: '${thirdpartyDir}/out/lib/', lib libraryFileName.
maker includeDirectories: lib includeDir.
!
Item was changed:
----- Method: StackIPhoneConfig>>plistKeys (in category 'bundle strings') -----
plistKeys
^super plistKeys,
#(CFBundleIconFile57
CFBundleIconFile72
CFBundleIconFile1024
UIDeviceFamily
+ UIFileSharingEnabled
+ VMMemorySize
+ ImageIsWritable
+ ImageIsScrollable
+ WebViewAsUI
+ WebViewUrl)
- UIFileSharingEnabled)
!
Item was changed:
----- Method: StackIPhoneConfig>>plistTemplate (in category 'bundle strings') -----
plistTemplate
self flag: #todo. "CFBundleDisplayName is using @CFBundleExecutable@ that's probably wrong"
^'<?xml version="1.0" encoding="UTF-8"?>
<!!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleDisplayName</key>
<string>@CFBundleExecutable@</string>
<key>CFBundleExecutable</key>
<string>@CFBundleExecutable@</string>
<key>CFBundleIconFile</key>
<string>@CFBundleIconFile@</string>
<key>CFBundleIconFiles</key>
<array>
<string>@CFBundleIconFile@</string>
<string>@CFBundleIconFile57@</string>
<string>@CFBundleIconFile72@</string>
<string>@CFBundleIconFile1024@</string>
</array>
<key>CFBundleIdentifier</key>
<string>@CFBundleIdentifier@</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>@CFBundleName@</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleResourceSpecification</key>
<string>ResourceRules.plist</string>
<key>CFBundleSignature</key>
<string>FRAC</string>
<key>CFBundleSupportedPlatforms</key>
<array>
<string>iPhoneOS</string>
</array>
<key>CFBundleVersion</key>
<string>1.1.7</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>MinimumOSVersion</key>
<string>3.1.3</string>
<key>NSMainNibFile</key>
<string>MainWindow</string>
<key>UIDeviceFamily</key>
<array>
@UIDeviceFamily@
</array>
<key>UIPrerenderedIcon</key>
<false/>
<key>UIStatusBarHidden</key>
<true/>
<key>UIFileSharingEnabled</key>
+ <@UIFileSharingEnabled@/>
+ <key>ImageIsWritable</key>
+ <@ImageIsWritable@/>
+ <key>ImageIsScrollable</key>
+ <@ImageIsScrollable@/>
+ <key>VMMemorySize</key>
+ <integer>@VMMemorySize@</integer>
+ <key>WebViewAsUI</key>
+ <@WebViewAsUI@/>
+ <key>WebViewUrl</key>
+ <string>@WebViewUrl@</string>
- <@UIFileSharingEnabled@/>
</dict>
</plist>
'!
Item was changed:
----- Method: StackIPhoneConfig>>sdkVersion (in category 'accessing') -----
sdkVersion
+ ^'6.0'!
- ^'5.1'!
Item was changed:
----- Method: StackIPhoneConfig>>setCommonProperties: (in category 'settings') -----
setCommonProperties: maker
maker set: 'CMAKE_CROSSCOMPILING' to: 'TRUE'.
maker set: 'CMAKE_SYSTEM_NAME' to: 'Darwin'.
maker set: 'CMAKE_SYSTEM_PROCESSOR' to: 'arm'.
maker set: 'SDKVER' toString: self sdkVersion.
+ maker set: 'DEVROOT' toString: ('/Applications/Xcode.app/Contents/Developer/Platforms/{target}.platform/Developer'
+ nameFormat: {'target'->self targetDevice} asDictionary).
+ maker set: 'SDKROOT' toString: '${DEVROOT}/SDKs/', self targetDevice,'${SDKVER}.sdk'.
- maker set: 'DEVROOT' toString: '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer'.
- maker set: 'SDKROOT' toString: '${DEVROOT}/SDKs/iPhoneOS${SDKVER}.sdk'.
maker set: 'CMAKE_OSX_SYSROOT' to: 'iphoneos${SDKVER}'.
maker set: 'CMAKE_FIND_ROOT_PATH' to: '"${SDKROOT}" "${DEVROOT}"'.
maker set: 'CMAKE_FIND_ROOT_PATH_MODE_PROGRAM' to: 'ONLY'.
maker set: 'CMAKE_FIND_ROOT_PATH_MODE_LIBRARY' to: 'ONLY'.
maker set: 'CMAKE_FIND_ROOT_PATH_MODE_INCLUDE' to: 'ONLY'.
maker set: 'CMAKE_EXE_LINKER_FLAGS' toString: '--sysroot ${SDKROOT} -L${SDKROOT}/usr/lib -L${SDKROOT}/usr/lib/system'.
maker set: 'CMAKE_C_FLAGS' toString: '--sysroot ${SDKROOT} -L${SDKROOT}/usr/lib -L${SDKROOT}/usr/lib/system'.
maker set: 'CMAKE_CXX_FLAGS' toString: '--sysroot ${SDKROOT} -L${SDKROOT}/usr/lib -L${SDKROOT}/usr/lib/system'.
maker addFrameworks: self frameworks.!
Item was changed:
----- Method: StackIPhoneConfig>>setGlobalOptions: (in category 'settings') -----
setGlobalOptions: maker
"set any CMake global options, before declaring a project in cmake file"
maker
set: 'CMAKE_C_COMPILER'
+ to: ('/Applications/Xcode.app/Contents/Developer/Platforms/{target}.platform/Developer/usr/bin/gcc'
+ nameFormat: {'target' -> self targetDevice} asDictionary).
- to: '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc'.
maker
set: 'CMAKE_CXX_COMPILER'
+ to: ('/Applications/Xcode.app/Contents/Developer/Platforms/{target}.platform/Developer/usr/bin/g++'
+ nameFormat: {'target' -> self targetDevice } asDictionary).
+ self architecture ifNotNil: [
+ maker set: 'CMAKE_OSX_ARCHITECTURES' to: self architecture ].
- to: '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/g++'.
- maker set: 'CMAKE_OSX_ARCHITECTURES' to: 'arm6'.
maker set: 'CMAKE_OSX_SYSROOT' to: '/'.
!
Item was added:
+ ----- Method: StackIPhoneConfig>>targetDevice (in category 'accessing') -----
+ targetDevice
+ ^'iPhoneOS'!
Item was added:
+ StackIPhoneConfig subclass: #StackSimulatorConfig
+ instanceVariableNames: ''
+ classVariableNames: ''
+ poolDictionaries: ''
+ category: 'CMakeVMMaker-IOS'!
Item was added:
+ ----- Method: StackSimulatorConfig>>architecture (in category 'accessing') -----
+ architecture
+ ^'i386'!
Item was added:
+ ----- Method: StackSimulatorConfig>>executableName (in category 'accessing') -----
+ executableName
+ ^'iStackVMSimulator'!
Item was added:
+ ----- Method: StackSimulatorConfig>>standardIncludes (in category 'source files') -----
+ standardIncludes
+ ^super standardIncludes, {'/Applications/Xcode.app/Contents/Developer/Platforms/{target}.platform/Developer/SDKs/{target}{sdkVersion}.sdk/usr/include/'
+ nameFormat: {'target'->self targetDevice. 'sdkVersion'->self sdkVersion} asDictionary}
+ !
Item was added:
+ ----- Method: StackSimulatorConfig>>targetDevice (in category 'accessing') -----
+ targetDevice
+ ^'iPhoneSimulator'!
More information about the Vm-dev
mailing list