ifrotz / iosfrotz

Frotz for iOS source (formerly at code.google.com/p/iphonefrotz)
Other
49 stars 16 forks source link

Trouble building out of the box #288

Closed glangmead closed 4 years ago

glangmead commented 6 years ago

On a fresh git clone, macOS 10.13.2, Xcode 9.2, I ran into a few issues preventing building

ld: warning: directory not found for option '-F/Users/craig/Desktop/Reveal.app/Contents/SharedSupport/iOS-Libraries' ld: library not found for -lPods-Frotz clang: error: linker command failed with exit code 1 (use -v to see invocation)

glangmead commented 6 years ago

I see that Reveal is a third party debugging tool and I don't have that, but that's just a linker warning. The actual error is about Pods-Frotz which I don't know what is.

spathiwa commented 6 years ago

Sorry for leaving things in a bad state.

DropBox discontinued support for their old API forcing me to upgrade Frotz to allow DropBox syncing to continue working, and the iOS libraries for the newer API version of it were built using CocoaPods, a Ruby-based module/dependency system.

It has some generated files that are not meant to be checked into source code control, and you’re supposed to install CocoaPods and run a command to update deps, but I attempted to make the build scripts robust in the face of CocoaPods not being installed so that it would automatically just build without DB support in that case, but it looks like I failed.

I won’t have time until this evening to look into the issue, but I think you can turn off the ifdef for DB support and uncheck the link reference to the Pods-Frotz and it might work.

On Jan 7, 2018, at 10:34 AM, glangmead notifications@github.com wrote:

I see that Reveal is a third party debugging tool and I don't have that, but that's just a linker warning. The actual error is about Pods-Frotz which I don't know what is.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ifrotz/iosfrotz/issues/288#issuecomment-355834718, or mute the thread https://github.com/notifications/unsubscribe-auth/AA0g5IHqFUUashFm3lfM-07sn2KJ-jWeks5tIPIAgaJpZM4RVqOv.

glangmead commented 6 years ago

Oh I hadn't used Cocopods before, so I installed it and have everything building now, with a couple minor patches:

diff --git a/ui/StoryMainViewController.m b/ui/StoryMainViewController.m index 3332e16..ea0f9c6 100644 --- a/ui/StoryMainViewController.m +++ b/ui/StoryMainViewController.m @@ -4549,6 +4549,7 @@ -(NSString)completeWord:(NSString)str prevString:(NSString)prevString isAmbig static NSString kDefaultDBTopPath = @"/Frotz";

static BOOL migateDropboxAuth() { +#ifdef FROTZ_DB_APP_KEY

if UseNewDropBoxSDK

 BOOL willPerformMigration = [DBClientsManager checkAndPerformV1TokenMigration:^(BOOL shouldRetry, BOOL invalidAppKeyOrSecret,
                                                                                 NSArray<NSArray<NSString *> *> *unsuccessfullyMigratedTokenData) {

@@ -4584,6 +4585,7 @@ static BOOL migateDropboxAuth() {

else

 return NO;

endif

+#endif }

if UseNewDropBoxSDK

diff --git a/Podfile b/Podfile index 84ebdfe..47cf0ac 100644 --- a/Podfile +++ b/Podfile @@ -1,4 +1,4 @@ -platform :ios, '8.0' +platform :ios, '9.0'

target 'Frotz' do pod 'ObjectiveDropboxOfficial'

spathiwa commented 4 years ago

Fixed in 1.8.4 (I think).