|
@@ -0,0 +1,40 @@
|
|
|
|
+ - implement bind to device functionality
|
|
|
|
+--- trunk.orig/src/supl-client.c 2011-10-21 20:51:38.000000000 +0200
|
|
|
|
++++ trunk/src/supl-client.c 2013-04-24 18:55:01.937252375 +0200
|
|
|
|
+@@ -252,6 +252,7 @@ static char *usage_str =
|
|
|
|
+ " --cell gsm:mcc,mns:lac,ci|wcdma:mcc,msn,uc set current gsm/wcdma cell id\n"
|
|
|
|
+ " --cell gsm:mcc,mns:lac,ci:lat,lon,uncert set known gsm cell id with position\n"
|
|
|
|
+ " --format|-f human machine parseable output\n"
|
|
|
|
++" --interface|-i iface bind to this interface\n"
|
|
|
|
+ " --debug|-d <n> 1 == RRLP, 2 == SUPL, 4 == DEBUG\n"
|
|
|
|
+ " --debug-file file write debug to file\n"
|
|
|
|
+ " --help|-h show this help\n"
|
|
|
|
+@@ -267,6 +268,7 @@ static struct option long_opts[] = {
|
|
|
|
+ { "cell", 1, 0, 0 },
|
|
|
|
+ { "debug", 1, 0, 'd' },
|
|
|
|
+ { "format", 1, 0, 'f' },
|
|
|
|
++ { "interface", 1, 0, 0},
|
|
|
|
+ { "test", 1, 0, 't' },
|
|
|
|
+ { "set-pos", 1, 0, 0 },
|
|
|
|
+ { "pos-helper", 1, 0, 0 },
|
|
|
|
+@@ -310,7 +312,7 @@ int main(int argc, char *argv[]) {
|
|
|
|
+ int opt_index;
|
|
|
|
+ int c;
|
|
|
|
+
|
|
|
|
+- c = getopt_long(argc, argv, "ad:f:t:", long_opts, &opt_index);
|
|
|
|
++ c = getopt_long(argc, argv, "ad:f:i:t:", long_opts, &opt_index);
|
|
|
|
+ if (c == -1) break;
|
|
|
|
+ switch (c) {
|
|
|
|
+ case 0:
|
|
|
|
+@@ -374,6 +376,11 @@ int main(int argc, char *argv[]) {
|
|
|
|
+ }
|
|
|
|
+ break;
|
|
|
|
+
|
|
|
|
++ case 'i':
|
|
|
|
++ strncpy(ctx.iface, optarg, IFNAMSIZ);
|
|
|
|
++ ctx.iface[IFNAMSIZ] = 0;
|
|
|
|
++ break;
|
|
|
|
++
|
|
|
|
+ case 'd':
|
|
|
|
+ {
|
|
|
|
+ int debug = atoi(optarg);
|