{"action":"created","issue":{"url":"https://api.github.com/repos/Sable/soot/issues/584","repository_url":"https://api.github.com/repos/Sable/soot","labels_url":"https://api.github.com/repos/Sable/soot/issues/584/labels{/name}","comments_url":"https://api.github.com/repos/Sable/soot/issues/584/comments","events_url":"https://api.github.com/repos/Sable/soot/issues/584/events","html_url":"https://github.com/Sable/soot/issues/584","id":151882114,"number":584,"title":"Can SPARK ignore library class？","user":{"login":"njupt-moon","id":16969197,"avatar_url":"https://avatars.githubusercontent.com/u/16969197?v=3","gravatar_id":"","url":"https://api.github.com/users/njupt-moon","html_url":"https://github.com/njupt-moon","followers_url":"https://api.github.com/users/njupt-moon/followers","following_url":"https://api.github.com/users/njupt-moon/following{/other_user}","gists_url":"https://api.github.com/users/njupt-moon/gists{/gist_id}","starred_url":"https://api.github.com/users/njupt-moon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/njupt-moon/subscriptions","organizations_url":"https://api.github.com/users/njupt-moon/orgs","repos_url":"https://api.github.com/users/njupt-moon/repos","events_url":"https://api.github.com/users/njupt-moon/events{/privacy}","received_events_url":"https://api.github.com/users/njupt-moon/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Sable/soot/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2016-04-29T14:35:05Z","updated_at":"2016-05-02T11:50:54Z","closed_at":null,"body":"@StevenArzt \r\nHi!\r\nAs I see, cg.cha has the phase option \"AppOnly\" to reduce the call graph edges within library classes. But it seems that there is not any similar options in cg.spark to implement the same function as \"AppOnly\" does, am I right?"},"comment":{"url":"https://api.github.com/repos/Sable/soot/issues/comments/216217243","html_url":"https://github.com/Sable/soot/issues/584#issuecomment-216217243","issue_url":"https://api.github.com/repos/Sable/soot/issues/584","id":216217243,"user":{"login":"StevenArzt","id":2691304,"avatar_url":"https://avatars.githubusercontent.com/u/2691304?v=3","gravatar_id":"","url":"https://api.github.com/users/StevenArzt","html_url":"https://github.com/StevenArzt","followers_url":"https://api.github.com/users/StevenArzt/followers","following_url":"https://api.github.com/users/StevenArzt/following{/other_user}","gists_url":"https://api.github.com/users/StevenArzt/gists{/gist_id}","starred_url":"https://api.github.com/users/StevenArzt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/StevenArzt/subscriptions","organizations_url":"https://api.github.com/users/StevenArzt/orgs","repos_url":"https://api.github.com/users/StevenArzt/repos","events_url":"https://api.github.com/users/StevenArzt/events{/privacy}","received_events_url":"https://api.github.com/users/StevenArzt/received_events","type":"User","site_admin":false},"created_at":"2016-05-02T11:50:53Z","updated_at":"2016-05-02T11:50:53Z","body":"That was indeed tougher than I first thought. Please update Soot and soot-infoflow-android. When computing the callgraph, make sure to set the appropriate options. The following code snippet works for me with the new version:\r\n\r\n```\r\n\t\tSetupApplication app = new SetupApplication\r\n\t\t            (\"D:/Tools/adt-bundle-windows-x86_64-20140321/sdk/platforms\",\r\n\t\t            \"D:\\\\Arbeit\\\\APKs\\\\Library23Check.apk\");\r\n\t\tapp.calculateSourcesSinksEntrypoints(\"D:/Arbeit/Android Analyse/soot-infoflow-android/SourcesAndSinks.txt\");\r\n\r\n\t\tsoot.G.reset();\r\n\r\n\t\tOptions.v().set_src_prec(Options.src_prec_apk);\r\n\t\t        Options.v().set_process_dir(Collections.singletonList(\"D:\\\\Arbeit\\\\APKs\\\\Library23Check.apk\"));\r\n\t\tOptions.v().set_android_jars(\"D:/Tools/adt-bundle-windows-x86_64-20140321/sdk/platforms\");\r\n\t\tOptions.v().set_whole_program(true);\r\n\t\tOptions.v().set_allow_phantom_refs(true);\r\n\t\tOptions.v().set_output_format(Options.output_format_none);\r\n\t\tOptions.v().setPhaseOption(\"cg.spark\", \"on\");\r\n\t\tnew SootConfigForAndroid().setSootOptions(Options.v());\r\n\r\n\t\tScene.v().loadNecessaryClasses();\r\n\t\tSootMethod entryPoint = app.getEntryPointCreator().createDummyMain();\r\n\t\tentryPoint.getActiveBody().validate();\r\n\t\t\r\n\t\tOptions.v().set_main_class(entryPoint.getSignature());\r\n\t\tScene.v().setEntryPoints(Collections.singletonList(entryPoint));\r\n\t\t\r\n\t\tPackManager.v().runPacks();\r\n\t\tCallGraph cg = Scene.v().getCallGraph();\r\n\t\tfor (Iterator<Edge> edgeIt = cg.iterator(); edgeIt.hasNext(); ) {\r\n\t\t\tEdge e = edgeIt.next();\r\n\t\t\tSystem.out.println(e);\r\n\t\t}\r\n```"}}