Permalink
Browse files

remove TouchDB 1.01 because it's broken without depending on private …

…repositories
  • Loading branch information...
1 parent 88ed71e commit bc3ee14d6d7d41e489c3358df5533f7221eae551 @explicitcall explicitcall committed Jan 22, 2013
Showing with 0 additions and 79 deletions.
  1. +0 −79 TouchDB/1.01/TouchDB.podspec
@@ -1,79 +0,0 @@
-license = <<EOT
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-EOT
-
-Pod::Spec.new do |s|
- version = '1.01'
-
-
- s.name = 'TouchDB'
- s.version = version
- s.license = {:type => 'Apache', :text => license}
- s.summary = 'CouchDB-compatible mobile database; Objective-C version.'
- s.homepage = 'https://github.com/couchbaselabs/TouchDB-iOS'
- s.author = { 'Jens Alfke' => 'jens@couchbase.com' }
-
- s.source = { :git => 'https://github.com/couchbaselabs/TouchDB-iOS.git',
- :tag => "v#{version}",
- :submodules => "true" }
-
- s.platform = :ios, '5.0'
-
-
- s.source_files = FileList['Source/**/*.{h,m}'].exclude(/GNUstep/).exclude(/_Tests/),
- FileList['vendor/oauthconsumer/**/*.{h,m,c}'].exclude(/OAHMAC_SHA1SignatureProvider\.m/),
- FileList['vendor/fmdb/src/**/*.{h,m}']
-
- s.header_dir = 'TouchDB'
-
- def s.post_install(target)
- src = config.project_pods_root.to_s() + '/TouchDB/Source'
-
- # Prepend some headers manually. The regular build does this with a prefix header, but
- # that pollutes the global namespace. (and conflicts with CouchCocoa)
- Dir.glob(src + '/**/*.m').each { |path|
- File.open( path, 'r+') { |f|
- firstLine = f.readline()
- if firstLine =~ /patched/
- next
- end
- f.rewind
-
- content = f.readlines()
- f.rewind
-
- f.puts '// patched during Pod install'
- f.puts '#import "TDJSON.h"'
- f.puts '#import "CollectionUtils.h"'
- f.puts '#import "Logging.h"'
- f.puts '#import "Test.h"'
-
- # add the version symbols to an arbitrary .m file
- if path =~ /TDServer\.m/
- f.puts "const unsigned char TouchDBVersionString[] __attribute__ ((used)) = \"@(#)PROGRAM:TouchDB PROJECT:TouchDB-#{version}\";"
- f.puts "const double TouchDBVersionNumber __attribute__ ((used)) = (double)#{version};"
- end
-
- f.puts
- f.puts content
- }
- }
- end
-
- s.dependency 'CocoaHTTPServer'
- s.dependency 'MYUtilities'
- s.dependency 'JSONKit'
-
- s.framework = 'SystemConfiguration'
- s.library = 'sqlite3'
-end

7 comments on commit bc3ee14

@davidquon
Contributor

What was the problem with this and have there been any thoughts in finding a way to make it work again? Thanks.

@keith
Member
keith commented on bc3ee14 Mar 21, 2013
@explicitcall
Contributor

actually, the main problem is that TouchDB git repository bundles custom FMDB with itself and some other libraries. Some of those require ARC, some of those don't. Depending on upstream FMDB isn't reliable in this case, and I wasn't able to create a suitable podspec which gives any possibility to turn off ARC for a subset of files (even when using subspecs). I'd rather say that this one CocoaPods/CocoaPods#532 is blocker for bringing recent versions of TouchDB to CocoaPods.

@fabiopelosin
Member

Why the subspecs didn't work to selectively enable ARC?

@explicitcall
Contributor

Actually, there isn't any documentation on subspecs and selectively enabling ARC with subspecs, all what I've found is scattered across github issues. Even if there is any documentation on this, I'd be grateful to know where it is. At least what I found didn't work for me. I don't remember any exact error messages. And as my own project, which needs TouchDB, is private, I was satisfied with my own Specs fork (https://github.com/explicitcall/Specs/commits/master) which contains forked FMDB and all other stuff which TouchDB needs and fairly recent TouchDB itself.

@fabiopelosin
Member

The documentation is available here. I think that a setup like the following should work:

# …snip
subspec "ARC" do |sp|
  sp.source_files = "file_pattern_for_arc"
  sp.requires_arc = true
end

subspec "NO-ARC" do |sp|
  sp.source_files = "file_pattern_for_no_arc"
  sp.requires_arc = false
end
# …snip
@fabiopelosin
Member

According to my finding in CocoaPods/CocoaPods#892 this setup would work.

Please sign in to comment.