graphhopper / graphhopper-ios

iOS Port of the GraphHopper road routing engine
https://www.graphhopper.com/open-source/
Apache License 2.0
69 stars 28 forks source link

Pod file #7

Open dimohamdy opened 9 years ago

dimohamdy commented 9 years ago

Add graphhopper to CocoaPods

ntpeters commented 9 years ago

+1

clns commented 9 years ago

Adding graphhopper-ios to CocoaPods means translating the java sources into Objective-C (which this repo does) and using the translated files to create the library. I absolutely agree with this, however we first need to have the java tests running on iOS ( #1 ) to make sure the library is fully functional.

At this point there is only a small demo that uses basic functionality from GraphHopper. We need the tests to make sure everything else is working. It's a bit more difficult to translate the tests because of the stuff that had to be commented out to make it work on iOS.

I'll try to start investigating how can we translate the tests. I'm open to any suggestions/contributions and I'd certainly appreciate them.

karussell commented 9 years ago

The XML stuff is not that important on iOS, we also do not have the import on Android.

So if the core tests like the storage and the algorithms work this would be already a nice start. (Separating the import from the core is still an open issue)

Is it possible to run device-independent Objective-C code on linux? This way I could easier help and we could use travis ci for it, so that it automatically runs after a push :)

And the unsafe can be safely ignored too. Also the commented helper methods do not look important (not sure about the isFileMapped)

clns commented 9 years ago

Yes, once we have them we can definitely use Travis. Not sure about running objc code on linux, it might be possible with GNUstep but I don't have any experience with that.

Sounds like it might not be that difficult. Can you outline the tests that are most important to have on iOS? So I can try to translate them and see where we are after that :smile:

karussell commented 9 years ago

It looks to me like all tests, except the reader package is possible on iOS.

Or expressed the other way around: at least DijkstraBidirectionRefTest.java and all storage tests would be needed (without unsafe)

Also PrepareContractionHierarchies (and its tests) is not necessary for iOS BUT it would be still nice to have the class (and its tests) so that we can run the DijkstraBidirectionCHTest.java or nearly everything under routing

Also here I would avoid as much manual intervention as possible :) E.g. I plan a bigger refactoring where the LevelGraphStorageTest won't exist

clns commented 9 years ago

Avoiding manual intervention sounds great to me :smile: Also I think we can get rid of most of the current "manual intervention" when the separation between the import and core is made.

karussell commented 9 years ago

Ok, created an issue for this https://github.com/graphhopper/graphhopper/issues/450

karussell commented 8 years ago

Why close this?

dimohamdy commented 8 years ago

i think it's not in the scope now

karussell commented 8 years ago

In which scope? We should and will make this happen, sometimes it takes a bit more time :)

dimohamdy commented 8 years ago

:+1:

clns commented 8 years ago

As @karussell said, we are going to do this. But to be able to publish it as a library on CocoaPods it needs to be stable and reliable, meaning we need to have the tests pass ( #1 ).

The major problem at the moment is that there's some code we had to strip out from the iOS port (for GraphHopper 0.5) to make it work. This is related to splitting up the import stuff from the core (https://github.com/graphhopper/graphhopper/issues/450), which will happen in a future release of GraphHopper. Once we have this, we will be able to refactor the iOS version and move forward with the tests.

karussell commented 7 years ago

BTW: CocoaPods might not be always desired https://tech.zalando.com/blog/how-the-zalando-ios-app-abandoned-cocoapods-and-reduced-build-time/

randyhbh commented 7 years ago

how is it going the cocoapods spec?

RaimundWege commented 6 years ago

One year later: how is it going? Currently we're building an App with Flutter and I'm trying to build a dart package for graphhopper but first I need a pod source. For now I will use a git repository as pod dependency but an official source would be nice.