From aa1f77f413585284f0564806f5cf13cc7d6172fe Mon Sep 17 00:00:00 2001 From: Tamir Duberstein Date: Sat, 24 Jan 2015 13:40:06 -0800 Subject: [PATCH] Add podspec --- .gitignore | 3 +++ Gemfile | 4 ++++ J2ObjC.podspec | 31 +++++++++++++++++++++++++++++++ 3 files changed, 38 insertions(+) create mode 100644 Gemfile create mode 100644 J2ObjC.podspec diff --git a/.gitignore b/.gitignore index 20923fdc05..9cd64d4115 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,9 @@ # Temp Files *~ +# Bundler +Gemfile.lock + # Build Output **/build_result/ dist/ diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000000..d9ca97cba0 --- /dev/null +++ b/Gemfile @@ -0,0 +1,4 @@ +source 'https://rubygems.org' + +gem 'cocoapods' +gem 'rubocop' diff --git a/J2ObjC.podspec b/J2ObjC.podspec new file mode 100644 index 0000000000..0b1036e1c0 --- /dev/null +++ b/J2ObjC.podspec @@ -0,0 +1,31 @@ +Pod::Spec.new do |s| + s.name = 'J2ObjC' + s.version = '0.9.5' + s.license = { type: 'Apache License, Version 2.0', file: 'LICENSE' } + s.summary = 'J2ObjC\'s JRE emulation library, emulates a subset of the Java runtime library.' + s.homepage = 'https://github.com/google/j2objc' + s.author = 'Google Inc.' + s.source = { + http: "https://github.com/google/j2objc/releases/download/#{s.version}/j2objc-#{s.version}.zip", + sha1: '6b53c2b47c9cd4c6678d0fee75b00039b83fc120', + } + + s.ios.deployment_target = '5.0' + s.osx.deployment_target = '10.7' + s.requires_arc = false + + # Top level attributes can't be specified by subspecs. + s.header_mappings_dir = 'dist/include' + + s.subspec 'lib' do |lib| + lib.subspec 'jre_emul' do |jre_emul| + jre_emul.public_header_files = %w( + dist/include/ + dist/include/java/**/* + dist/include/libcore/**/* + ) + jre_emul.vendored_libraries = "dist/#{lib.base_name}/lib#{jre_emul.base_name}.a" + jre_emul.libraries = jre_emul.base_name, 'icucore', 'z' + end + end +end