How do I include openFrameworks in a MonoDevelop C/C++ Project?
I set the include path to the OF_ROOT/libs and can do #include <openFrameworks/ofMain.h> but I get an error that says the "ofConstants.h" file does not exist, but it does. It is somewhere in the OF_ROOT/libs/openFrameworks/ subdirectory.
ofMain.h includes the files like ofConstants.h like so #include "ofConstants.h"
Help! :)
It looks like openFrameworks has a strange setup for their headers, and needs include paths for all the subdirectories: https://github.com/openframeworks/openFrameworks/blob/master/apps/devApps/fboTester/emptyExample_linux.cbp#L47
Related
Hi I would like to solve how I can fix with linker error.
What I wanted to do is to include header file which is mysql.h from /usr/local/include.(I'm using mac book)
But when compiling the header file which is below, compiler says "Undefined symbols for architecture"
#include </usr/local/include/mysql.h>
I obviously installed mysql and connecter-c.
Please teach me how to fix it and why mysql.h is not included.
Best regards,
please check the format in which you have included the header file.
#include </usr/local/include/mysql.h>
should be
#include "/usr/local/include/mysql.h"
the "<>" is used to include system header files. please use double quotes ("") to include user header files.
I have included the cocos-ext.h in one of my header files and added the extension namespace. Visual studio has no issue with the code, successfully finding it, however, when I go into the terminal and try to compile for android, it says file cannot be found in the extention include file. Is there somewhere I need to put the file? Or add it to Android.mk?
I am running cocos2d-x 3.0r2 with code in C++
Thanks.
If anyone else encounters this problem, check this page:
cocos forums
The meat of it is to include the header at the top of your file:
#include "extensions/cocos-ext.h"
Then add the extensions to the Android.mk file in the jni folder:
LOCAL_WHOLE_STATIC_LIBRARIES := cocos2dx_static
LOCAL_WHOLE_STATIC_LIBRARIES += cocosdenshion_static
LOCAL_WHOLE_STATIC_LIBRARIES += box2d_static
LOCAL_WHOLE_STATIC_LIBRARIES += cocos_extension_static // add this
include $(BUILD_SHARED_LIBRARY)
$(call import-module,2d)
$(call import-module,audio/android)
$(call import-module,Box2D)
$(call import-module,extensions) // add this
Are your header search paths set for compiling from a terminal? I'd check Visual Studio for where it is searching and make sure the same path is set when compiling from the terminal.
Have a look here: http://cocos2d-x.org/wiki/How_to_run_cpp-tests_on_Android
FYI Since I was having this problem as well:
Include:
#include "cocos-ext.h"
In Android.mk make sure you have:
LOCAL_WHOLE_STATIC_LIBRARIES += cocos_extension_static
$(call import-module,extensions)
AND:
LOCAL_C_INCLUDES += $(LOCAL_PATH)/../../../extensions
to wherever extensions is for you.
Hopefully this helps.
Original Post: http://www.cocoachina.com/bbs/simple/?t201982.html
I'm using Jade without Node, I'm simply using the software Prepros to compile the templates to static HTML.
I want to include partials that are outside of the folder the Jade templates are in, like so:
include /partials/foo.html
However, using paths that begin with a / with include in Prepros gives the following error:
the "basedir" option is required to use "include" with "absolute" paths
Usually you could set the basedir using something like app.locals.basedir = __dirname + '/views', but there's no way to do this with Prepros. Is there some other way?
It is security restriction imposed by jade language. I have added a workaround in Prepros Jade compiler to fix this issue, fix will be available from the next version of Prepros.
You can just deleted / and it will works.
You also can add the path in the root folder and just call it like foot.html.
I'm trying to setup limeJS, the issue is the Internet connection is a problem. I had closure library, box2d, closure compiler and closure templates downloaded separately as .rar files, but I can't find a guide anywhere to set it up like this, everyone just uses(and with reason!!!) the python bin/lime.py init command to get it working. I managed to figure out(yay!) how to setup box2d and closure library but what about the other two?
My laptop is running 64 bits Windows 7. Any help appreciated
All I need is an advice on directory structure, like where to drop the compiler.jar and soy templates .js files, so that when I run the update/create command it doesn't try to download the compiler or templates like it does right now.
I got it working, after taking a quick look at the lime.py file it told me everything I needed, for example both the SoyJs templates file and the compiler need to be in the /path/to/lime/bin/external folder and for example, the lime.py file was expecting a compiler file named compiler-dateOfLatestCompiler.jar instead of compiler.jar.
In general, If you have LimeJS built up in one machine using Python and all, you can just copy paste the whole package anywhere you want and use it just as ususal.
You don't need network once you have all the files/codes for Lime is downloaded.
Infact, you dont even need python for normal development tasks(Python is required to build your js file once you complete development though)
In a widget inside a module, I loaded a language file using
$this->load->lang('application')
However, PyroCMS returns this error
An Error Was Encountered
Unable to load the requested language file: language/english/application_lang.php
I am sure(and double checked) that the module has that language file. So why can't PyroCMS load it? Is it checking only in the default PyroCMS system language files and not in the module language files perhaps?
EDIT: It seems to be that it is the case. When I tried adding application_lang in the system language folder, the error is gone. Is this expected behaviour?
Which version of PyroCMS are you using?
In 1.3.2, you should use something like the following:
$this->load->language('application');
This will cause Pyro to look for the language file in:
shared_addons/modules/module_name/language/english/application_lang.php
I believe lang('...') is indeed reserved for system language files.
Hope that helps!