Cocos2d-x HockeyApp integration - cocos2d-x-3.x

I tried to integrate HockeyApp in my cocos2d-x project, using following link:-
http://support.hockeyapp.net/kb/client-integration-android/hockeyapp-for-android-ndk-early-access
But it gives me following error when I tried to run ndk-build command
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:47:7: error: expected nested-name-specifier before 'AndroidLogBufferWriteFunc'
using AndroidLogBufferWriteFunc = int (*)(int bufID, int prio, const char *tag,
^
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:47:7: error: 'AndroidLogBufferWriteFunc' has not been declared
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:47:33: error: expected ';' before '=' token
using AndroidLogBufferWriteFunc = int (*)(int bufID, int prio, const char *tag,
^
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:47:33: error: expected unqualified-id before '=' token
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:53:1: error: 'AndroidLogBufferWriteFunc' does not name a type
AndroidLogBufferWriteFunc g_android_log_buf_write = nullptr;
^
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc: In function 'void logger::initializeCrashLogWriter()':
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:60:3: error: 'g_android_log_buf_write' was not declared in this scope
g_android_log_buf_write = reinterpret_cast<AndroidLogBufferWriteFunc>(
^
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:60:46: error: expected type-specifier before 'AndroidLogBufferWriteFunc'
g_android_log_buf_write = reinterpret_cast<AndroidLogBufferWriteFunc>(
^
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:60:46: error: expected '>' before 'AndroidLogBufferWriteFunc'
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:60:46: error: expected '(' before 'AndroidLogBufferWriteFunc'
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:60:46: error: 'AndroidLogBufferWriteFunc' was not declared in this scope
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:61:54: error: expected ')' before ';' token
dlsym(RTLD_DEFAULT, "__android_log_buf_write"));
^
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc: In function 'int logger::writeToCrashLog(const char*)':
jni/../../breakpad/android/google_breakpad/../../src/client/linux/log/log.cc:68:7: error: 'g_android_log_buf_write' was not declared in this scope
if (g_android_log_buf_write) {
^
make: *** [obj/local/armeabi/objs/breakpad_client/src/client/linux/log/log.o] Error 1

GCC 4.6.3 doesn't support C++11 type aliases:
in
Breakpad\src\client\linux\log\log.cc
replace
using AndroidLogBufferWriteFunc = int (*)(int bufID, int prio, const char *tag,const char *text);
with
typedef int (*AndroidLogBufferWriteFunc)(int bufID, int prio, const char *tag,const char *text);

Related

I'm having this Error when I'm debugging and building my Flutter Project on VSCode

Launching lib\main.dart on sdk gphone x86 arm in debug mode...
lib\main.dart:1
../flutter/.pub-cache/hosted/pub.dartlang.org/http-0.13.1/lib/src/io_client.dart:30:72: Error: Expected ';' after this.
var ioRequest = await _inner!.openUrl(request.method, request.url))
^
../flutter/.pub-cache/hosted/pub.dartlang.org/http-0.13.1/lib/src/io_client.dart:30:73: Error: Expected an identifier, but got ')'.
Try inserting an identifier before ')'.
var ioRequest = await _inner!.openUrl(request.method, request.url))
^
../flutter/.pub-cache/hosted/pub.dartlang.org/http-0.13.1/lib/src/io_client.dart:30:73: Error: Expected ';' after this.
var ioRequest = await _inner!.openUrl(request.method, request.url))
^
../flutter/.pub-cache/hosted/pub.dartlang.org/http-0.13.1/lib/src/io_client.dart:30:73: Error: Unexpected token ')'.
var ioRequest = await _inner!.openUrl(request.method, request.url))
^
../flutter/.pub-cache/hosted/pub.dartlang.org/http-0.13.1/lib/src/io_client.dart:32:9: Error: Expected an identifier, but got '..'.
Try inserting an identifier before '..'.
..followRedirects = request.followRedirects
^^

How to add google maps to flutter app which works also on web platform and still work in each platform?

I recently add web support to my app , but the problem was google maps ,
I'm using flutter_google_maps fro android and IOS but for web , I Had some problems :
I used google_map plugin for web and it worked for web , but when I try to run the project on mobile an error show up that "dart:html" is not found .
I searched for the error , I found the universal_html library which also did't work for me .
this is my code :
// import 'package:universal_html/html.dart' as html;
import 'dart:html';
import 'package:flutter/material.dart';
import 'package:google_maps/google_maps.dart';
import 'dart:ui' as ui;
class GoogleMap extends StatelessWidget {
#override
Widget build(BuildContext context) {
String htmlId = "7";
// ignore: undefined_prefixed_name
ui.platformViewRegistry.registerViewFactory(htmlId, (int viewId) {
final myLatlng = LatLng(25.373327, 55.399455);
// another location
final myLatlng2 = LatLng(1.4521, 103.9198);
final mapOptions = MapOptions()
..zoom = 14.4746
..center = LatLng(25.373327, 55.399455);
final elem = DivElement()
..id = htmlId
..style.width = "100%"
..style.height = "100%"
..style.border = 'none';
final map = GMap(elem, mapOptions);
final marker = Marker(MarkerOptions()
..position = myLatlng
..map = map
..title = 'Hello World!'
..label = 'h'
..icon =
'https://developers.google.com/maps/documentation/javascript/examples/full/images/beachflag.png');
// Another marker
Marker(
MarkerOptions()
..position = myLatlng2
..map = map,
);
final infoWindow =
InfoWindow(InfoWindowOptions()..content = contentString);
marker.onClick.listen((event) => infoWindow.open(map, marker));
return elem;
});
return HtmlElementView(viewType: htmlId);
}
}
var contentString = '<div id="content">' +
'<div id="siteNotice">' +
'</div>' +
'<h1 id="firstHeading" class="firstHeading">Uluru</h1>' +
'<div id="bodyContent">' +
'<p><b>Uluru</b>, also referred to as <b>Ayers Rock</b>, is a large ' +
'sandstone rock formation in the southern part of the ' +
'Northern Territory, central Australia. It lies 335 km (208 mi) ' +
'south west of the nearest large town, Alice Springs; 450 km ' +
'(280 mi) by road. Kata Tjuta and Uluru are the two major ' +
'features of the Uluru - Kata Tjuta National Park. Uluru is ' +
'sacred to the Pitjantjatjara and Yankunytjatjara, the ' +
'Aboriginal people of the area. It has many springs, waterholes, ' +
'rock caves and ancient paintings. Uluru is listed as a World ' +
'Heritage Site.</p>' +
'<p>Attribution: Uluru, <a href="https://en.wikipedia.org/w/index.php?title=Uluru&oldid=297882194">' +
'https://en.wikipedia.org/w/index.php?title=Uluru</a> ' +
'(last visited June 22, 2009).</p>' +
'</div>' +
'</div>';
and this is the log :
Launching lib\main.dart on Mi 9 SE in debug mode...
Compiler message:
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.dart:19:8: Error: Not found: 'dart:html'
import 'dart:html' show Node, Document;
^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/js_wrapping-0.5.0/lib/js_wrapping.dart:9:8: Error: Not found: 'dart:js'
import 'dart:js';
^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/js_wrapping-0.5.0/lib/js_wrapping.dart:11:1: Error: Not found: 'dart:js'
export 'dart:js';
^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/js_wrapping-0.5.0/lib/adapter/js_list.dart:9:8: Error: Not found: 'dart:js'
import 'dart:js';
^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/js_wrapping-0.5.0/lib/adapter/js_map.dart:9:8: Error: Not found: 'dart:js'
import 'dart:js';
^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.dart:203:45: Error: Type 'Node' not found.
with MapMixin<ControlPosition, MVCArray<Node>> {
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.dart:207:12: Error: Type 'Node' not found.
MVCArray<Node> operator [](covariant ControlPosition key) {
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.dart:214:51: Error: Type 'Node' not found.
void operator []=(ControlPosition key, MVCArray<Node> value) {
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.dart:226:12: Error: Type 'Node' not found.
MVCArray<Node> remove(Object key) {
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/data/data_geometry_collection.dart:39:35: Error: Type 'JsObject' not found.
_DataGeometryCollection.created(JsObject o) : super.created(o);
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/data/data_multi_line_string.dart:39:32: Error: Type 'JsObject' not found.
_DataMultiLineString.created(JsObject o) : super.created(o);
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/data/data_multi_polygon.dart:43:29: Error: Type 'JsObject' not found.
_DataMultiPolygon.created(JsObject o) : super.created(o);
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/data/data_polygon.dart:37:24: Error: Type 'JsObject' not found.
_DataPolygon.created(JsObject o) : super.created(o);
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map/map.dart:19:17: Error: Type 'Node' not found.
factory _GMap(Node mapDiv, [MapOptions opts]) => null;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map/map.dart:28:3: Error: Type 'Node' not found.
Node get div => _getDiv();
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map/map.dart:29:3: Error: Type 'Node' not found.
Node _getDiv();
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/image_map_type.dart:23:3: Error: Type 'Node' not found.
Node Function(Point tileCoord, num zoom, Document ownerDocument) getTile;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/image_map_type.dart:23:44: Error: Type 'Document' not found.
Node Function(Point tileCoord, num zoom, Document ownerDocument) getTile;
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/image_map_type.dart:24:20: Error: Type 'Node' not found.
void releaseTile(Node tile);
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/map_type.dart:21:3: Error: Type 'Node' not found.
Node Function(Point tileCoord, num zoom, Document ownerDocument) getTile;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/map_type.dart:21:44: Error: Type 'Document' not found.
Node Function(Point tileCoord, num zoom, Document ownerDocument) getTile;
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/map_type.dart:22:20: Error: Type 'Node' not found.
void releaseTile(Node tile);
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/styled_map_type.dart:23:3: Error: Type 'Node' not found.
Node Function(Point tileCoord, num zoom, Document ownerDocument) getTile;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/styled_map_type.dart:23:44: Error: Type 'Document' not found.
Node Function(Point tileCoord, num zoom, Document ownerDocument) getTile;
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/map_types/styled_map_type.dart:24:20: Error: Type 'Node' not found.
void releaseTile(Node tile);
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/mvc/mvcarray.dart:29:21: Error: Type 'JsObject' not found.
_MVCArray.created(JsObject o, [Codec<E, dynamic> codec])
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/overlays/map_panes.dart:21:3: Error: Type 'Node' not found.
Node floatPane;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/overlays/map_panes.dart:22:3: Error: Type 'Node' not found.
Node mapPane;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/overlays/map_panes.dart:23:3: Error: Type 'Node' not found.
Node markerLayer;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/overlays/map_panes.dart:24:3: Error: Type 'Node' not found.
Node overlayLayer;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/overlays/map_panes.dart:25:3: Error: Type 'Node' not found.
Node overlayMouseTarget;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/save_to_google_maps/save_widget.dart:19:23: Error: Type 'Node' not found.
factory _SaveWidget(Node container, [SaveWidgetOptions opts]) => null;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/services/directions_renderer.dart:25:3: Error: Type 'Node' not found.
Node get panel => _getPanel();
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/services/directions_renderer.dart:26:3: Error: Type 'Node' not found.
Node _getPanel();
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/services/directions_renderer.dart:35:13: Error: Type 'Node' not found.
set panel(Node panel) => _setPanel(panel);
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/services/directions_renderer.dart:36:18: Error: Type 'Node' not found.
void _setPanel(Node panel);
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/services/directions_renderer_options.dart:27:3: Error: Type 'Node' not found.
Node panel;
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/street_view/street_view_panorama.dart:19:31: Error: Type 'Node' not found.
factory _StreetViewPanorama(Node container,
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/core/street_view/street_view_panorama.dart:62:10: Error: Type 'JsObject' not found.
Stream<JsObject> get onCloseclick => getStream(this, 'closeclick');
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.g.dart:11:45: Error: Type 'Node' not found.
with MapMixin<ControlPosition, MVCArray<Node>> {
^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.g.dart:13:20: Error: Type 'JsObject' not found.
Controls.created(JsObject o) : super.created(o);
^^^^^^^^
/F:/Flutter/cod/flutter_windows_v1.5.4-hotfix.2-stable/flutter/.pub-cache/hosted/pub.dartlang.org/google_maps-3.4.1/lib/src/google_maps_src.g.dart:16:12: Error: Type 'Node' not found.
MVCArray<Node> operator [](covariant ControlPosition key) {
^^^^
You can load the correct dependency at run-time.
For this example I'd assume you want to show a widget with the correct maps.
We need to create 4 files:
mobile.dart
web.dart
unsupported.dart
maps.dart
maps.dart:
This will decide at runtime which file is needed, you must import always this file only.
export 'unsupported.dart'
if (dart.library.html) 'web.dart'
if (dart.library.io) 'mobile.dart';
In the rest 3 dart files, you can define your class and functions. e.g a function that builds the map
unsupported.dart:
class MapUtils {
static Widget buildMap() {
//nothing to do here
}
}
mobile.dart:
class MapUtils {
static Widget buildMap() {
//import the mobile google maps and build the widget
}
}
web.dart:
class MapUtils {
static Widget buildMap() {
//import the web google maps and build the widget
}
}

error while compiling with matlab mex

I am try to compile using matlab mex, but i keep receiving this error:
Warning: You are using gcc version "5.4.0-6ubuntu1~16.04.1)". The version
currently supported with MEX is "4.2.3".
For a list of currently supported compilers see:
http://www.mathworks.com/support/compilers/current_release/
In file included from descriptor.h:4:0,
from calc_shot.cpp:11:
mesh.h: In function ‘double magnitude(const vec3d<T>&)’:
mesh.h:106:9: error: ‘sqrt’ is not a member of ‘std’
return std::sqrt((v1.x*v1.x) + (v1.y*v1.y) + (v1.z*v1.z));
^
In file included from calc_shot.cpp:11:0:
descriptor.h: At global scope:
descriptor.h:7:57: error: expected class-name before ‘{’ token
class invalid_mesh_descriptor : public std::logic_error {
^
descriptor.h: In constructor ‘invalid_mesh_descriptor::invalid_mesh_descriptor()’:
descriptor.h:9:57: error: expected class-name before ‘(’ token
explicit invalid_mesh_descriptor() : std::logic_error("Exception invalid_mesh_descriptor caught.") {}
^
descriptor.h:9:57: error: expected ‘{’ before ‘(’ token
descriptor.h: In constructor ‘invalid_mesh_descriptor::invalid_mesh_descriptor(const string&)’:
descriptor.h:10:70: error: expected class-name before ‘(’ token
invalid_mesh_descriptor(const std::string& msg) : std::logic_error("Exception invalid_mesh_descriptor caught: "+msg) {}
^
descriptor.h:10:70: error: expected ‘{’ before ‘(’ token
descriptor.h: In function ‘std::ostream& operator<<(std::ostream&, const vec_descriptor<T>&)’:
descriptor.h:123:45: error: no match for ‘operator<<’ (operand types are ‘std::ostream {aka std::basic_ostream<char>}’ and ‘const char [2]’)
for (size_t k=1; k < d.size(); ++k) s << " " << d(k);
^
In file included from /usr/include/c++/5/string:52:0,
from descriptor.h:5,
from calc_shot.cpp:11:
/usr/include/c++/5/bits/basic_string.h:5172:5: note: candidate: template<class _CharT, class _Traits, class _Alloc> std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&, const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&)
operator<<(basic_ostream<_CharT, _Traits>& __os,
^
/usr/include/c++/5/bits/basic_string.h:5172:5: note: template argument deduction/substitution failed:
In file included from calc_shot.cpp:11:0:
descriptor.h:123:48: note: mismatched types ‘const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>’ and ‘const char [2]’
for (size_t k=1; k < d.size(); ++k) s << " " << d(k);
^
mex: compile of ' "calc_shot.cpp"' failed.
i used to compile this code with LD_PRELOAD but at the moment i do not remember the argument, how can i solve?
solution:
mex -v calc_shot.cpp shot_descriptor.cpp -DUSE_FLANN -I"C:\Program Files\flann\include" -I/usr/include/eigen3
using this command the programs works like a charm

windows r inside rcpp eclipse

I'm trying to use Rinside in an IDE, Eclipse. Follow step by step manual
http://blog.fellstat.com/?p=170
However, when you Build All I mark the following errors
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:55:17: error: 'internal' does not name a type
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:68:21: error: expected ')' before 'charsxp'
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:73:23: error: 'StringProxy' does not name a type
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:73:36: error: ISO C++ forbids declaration of 'proxy' with no type [-fpermissive]
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:92:23: error: expected ')' before 'x'
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:97:35: error: declaration of 'operator=' as non-function
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:97:32: error: expected ';' at end of member declaration
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:97:41: error: expected ')' before 'x'
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:100:35: error: declaration of 'operator=' as non-function
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:100:32: error: expected ';' at end of member declaration
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:100:40: error: expected ')' before 'x'
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:103:41: error: 'StringProxy' does not name a type
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:103:54: error: ISO C++ forbids declaration of 'proxy' with no type [-fpermissive]
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:125:42: error: 'StringProxy' does not name a type
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:125:55: error: ISO C++ forbids declaration of 'proxy' with no type [-fpermissive]
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:133:36: error: declaration of 'operator+=' as non-function
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:133:32: error: expected ';' at end of member declaration
C:/R/R-2.15.2/library/Rcpp/include/Rcpp/string.h:133:41: error: expected ')' before 'x'
In file included from c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64-mingw32/4.6.3/../../../../include/c++/4.6.3/cwchar:46:0,
from c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64-mingw32/4.6.3/../../../../include/c++/4.6.3/bits/postypes.h:42,
from c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64-mingw32/4.6.3/../../../../include/c++/4.6.3/iosfwd:42,
from c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64-mingw32/4.6.3/../../../../include/c++/4.6.3/ios:39,
from c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64-mingw32/4.6.3/../../../../include/c++/4.6.3/ostream:40,
from c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64- mingw32/4.6.3/../../../../include/c++/4.6.3/iterator:64,
from C:/R/R-2.15.2/library/Rcpp/include/RcppCommon.h:57,
from C:/R/R-2.15.2/library/Rcpp/include/Rcpp.h:27,
from ../src/main.cpp:12:
c:\r\rtools\gcc-4.6.3\bin\../lib/gcc/i686-w64-mingw32/4.6.3/../../../../i686-w64- mingw32/include/wchar.h:12:32: error: expected '}' before end of line
In file included from C:/R/R-2.15.2/include/R_ext/RS.h:26:0,
from C:/R/R-2.15.2/include/R.h:44,
from C:/R/R-2.15.2/library/Rcpp/include/RcppCommon.h:32,
from C:/R/R-2.15.2/library/Rcpp/include/Rcpp.h:27,
from ../src/main.cpp:12:
And the error list continues
Somebody help me, really I did everything and nothing helps.
thanks

why am i getting these syntax errors when trying to implement system call

still working on this system call!!!
i have added a system call to a kernel, compiled and the OS is running off it.
now i am getting syntax error on the compilation of my test application.
testmycall.h
#include<linux/unistd.h>
#define __NR_mycall 244
_syscall1(long, mycall, int, i)
testmycall.c
#include<stdio.h>
#include "testmycall.h"
int main(int argc, char *argv[])
{
printf("%d\n", mycall(15));
}
here is the error
stef#ubuntu:~$ gcc -o testmycall testmycall.c
In file included from testmycall.c:3:
testmycall.h:7: error: expected ‘)’ before ‘mycall’
stef#ubuntu:~$ gcc -o testmycall testmycall.c
In file included from testmycall.c:3:
testmycall.h:7: error: expected declaration specifiers or ‘...’ before ‘mycall’
testmycall.h:7: error: expected declaration specifiers or ‘...’ before ‘i’
testmycall.c: In function ‘_syscall1’:
testmycall.c:7: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
testmycall.h:7: error: parameter name omitted
testmycall.h:7: error: parameter name omitted
testmycall.c:11: error: expected ‘{’ at end of input
stef#ubuntu
i have added in the syscall instead of _syscall1
now i get this error
stef#ubuntu:~$ gcc -o testmycall testmycall.c
testmycall.c: In function ‘syscall’:
testmycall.c:7: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
testmycall.c:11: error: expected ‘{’
this is the app, any ideas why???
I believe the _syscallN() macros were removed from the kernel headers around 2.6.18 or so.
The (not especially helpful) error messages from gcc are due to _syscall1 not being defined at all - you get the same errors if you write:
any_old_rubbish_here(long, mycall, int, i)
The syscall() function should work. man syscall for details.
The _syscall macros are obsolete and should not be used, instead use syscall, eg.
#define _GNU_SOURCE
#include <unistd.h>
...
printf("%d\n", syscall(__NR_mycall, 15));
Here's my test program:
#define _GNU_SOURCE
#include <stdio.h>
#include <unistd.h>
#define __NR_mycall 244
int main(int argc, char **argv)
{
printf("%d\n", syscall(__NR_mycall,15));
return 0;
}