IRC Log Viewer » #firebreath » 2011-07-11

IRC Nick Time (GMT-7) Message
someone-noone 02:07 Good morning\evening!
linearray 02:07 hi
someone-noone 02:07 linearray: are you using xcode 4?
linearray 02:07 yes
someone-noone 02:07 are your building process is fast?
Because mine is not if to compare it with xcode 3
linearray 02:07 hm it works ok
but I'm using xcode 4.2 build 4C114
someone-noone 02:07 My test plugin is compiling > 5 mins
i had the same version...
have*
linearray 02:07 ok
and I upgraded to 16 GB RAM, because xcode is using ram like crazy
someone-noone 02:07 yeap... maybe this is a problem..
i've 4GB
But i've noticed that it writes a lot of data on HDD, up to 10mb\s
And i've another problem that i was solving the whole day (yesterday). New llvm compiler fails to build asm code for i386-architecture of ffmpeg libraries that i want to use in firebreath project.
Now i can't make universal binary for it, only x86_64
linearray 02:07 hmm
someone-noone 02:07 Even i was asking this problem on #llvm irc channel and nobody knows and nobody cares about apple ggc compiler there.
When i googled this error, i've found that it's llvm problem.
But there was no solution
linearray 02:07 well, you could turn llvm off :)
and use gcc
someone-noone 02:07 yeah... probably i will compile for i386 on gcc and make llvm+gcc fat binary
Is there any tool for fast switching c compilers?
or should i use "host" flags?
linearray 02:07 you can change it in xcode project settings
someone-noone 02:07 the problem is, that ffmpeg has no xcodeproject file :). So it's must to build it from console by ./configure + make
linearray 02:07 then I would try to somehow pass the compiler path to configure/make
someone-noone 03:07 Woohoo! Finally, i did it and it works :D
linearray 03:07 cool, what did you do?
someone-noone 03:07 i used gcc-4.2 compiler
for i386 architecture
as you said
someone-noone 04:07 should i perform changes in xcode 4 after using prepmac ?
i'm not sure, because it's asking for removing some PREBINDING settings
and i don't know should i do it or no
linearray 04:07 whatever you do, it will be gone the next time you run prepmac
someone-noone 04:07 so should i justs ignore this?
linearray 04:07 I got the same notice about prebinding... I think it didn't make much difference
yes
someone-noone 04:07 i hate this life
omg, now i'm getting architecture mismatch error, while i'm having fat-binary library
linearray 04:07 hehe, not sure if the next one will be any better
hm, don't know much about fat libraries
someone-noone 04:07 Undefined symbols for architecture i386: "_uncompress", referenced from: _svq3_decode_init in libavcodec.a(svq3.o) ld: symbol(s) not found for architecture i386 collect2: ld returned 1 exit status
tool -vf libavcodec.a
otool -vf libavcodec.a
Fat headers fat_magic FAT_MAGIC nfat_arch 2 architecture i386 ... architecture x86_64
WTF? 0_0
linearray 04:07 well, this is a linker error
libavcodec needs _svq3_decode_init and the linker cannot find it
ah, no
i'm too sleepy yet.
someone-noone 04:07 nm libavcodec.a > test.txt
then in test.txt i can find _svq3_decode_init symbol
but, i'm not sure that it is either i386 or x86_64
linearray 04:07 libavcodec needs _uncompress, and I think that's in zlib
someone-noone 04:07 that's idea!
linearray 04:07 I was reading that line wrong before. sorry
someone-noone 04:07 trying to build it with -lz flag..
if libz is not fat binary library i will kill myself :D
linearray 04:07 well
I think you need to provide libz yourself
not sure and cannot check right now if Mac OS X installs one for you
someone-noone 04:07 will see that
also there are such libs as libc
linearray 04:07 ah ok, there is a libz in /usr/lib
and it's fat ;)
someone-noone 04:07 sorry, my inet was down
libz is a fat binary on my system
so i've solved that error
someone-noone2 05:07 hm
FireBreathBot 05:07 someone-noone2: 03 Jul 14:46Z <taxilian> tell someone-noone2 ask your question and I'll leave a message with FireBreathBot for you when I get back, since you keep missing me
someone-noone2 05:07 getting strange things with my qwebirc
ld: illegal text reloc to non_lazy_ptr from /ffmpeg-0.8/builduni/lib/libavcodec.a(ac3.o) in _ff_ac3_bit_alloc_calc_psd for architecture i386
any ideas?
someone-noone 05:07 lol, xcode eats my hdd
~3gb in hour
wtf? he says he is "Indexing"
linearray 05:07 yes
someone-noone 05:07 i can't work! Can i disable it?
linearray 05:07 nope
this is what most people hate about xcode 4 :)
only way out is xcode3 or not using it at all
someone-noone 05:07 i will try to use xcodebuild instead
linearray 05:07 or adding more ram
someone-noone 05:07 that is stupid
can't they just use indexing more slowly, but without need of huge amount of ram?
linearray 05:07 hehe
I believe this is due to boost
and heavy use of templates
someone-noone 05:07 yeah... boost is overheaded
i'm in despair
seems to be that next error is unfixable
why should i always to make it all linking right instead of just clear programming? ...
third day i'm stamping on one place...
:(
thinking aloud
someone-noone 06:07 linearray: are you signed on Apple's developer program?
Probably, i found the solution. I need to pass -fvisibility=hidden to my linker... but now i don't know how i can make it in xcode 4 :)
someone-noone 07:07 found how i can do it...
but it didn't help :(
linearray 08:07 someone-noone: what if I say yes, what if I say no? :)
someone-noone 08:07 http://hi-im-shigerello.blogspot.com/2011/04/transition-mayhem-xcode-4.html here is said that similar problem is discussed in in Apple forum
so i wanted you to look that topic and to tell me if there any solution
because i cannot due to i don't have that membership
but i guess that there is no solution there...
so you may not do anything
but if you have time...
linearray 08:07 hehe, I'm not a member there
whenever I need something from the dev program I have to bother a friend of mine
someone-noone 08:07 then forget it :)
now i'm downloading xcode 3... if that will not solve my problem i will kill that kitten :D
linearray 08:07 hehehe
someone-noone 08:07 is it possible to have xcode 3 and 4 at one time?
linearray 08:07 yes
you need to specify a different directory when installing
someone-noone 08:07 okay, thx
i will try that
linearray 08:07 I'm quite fed up with apple as well, because of xcode 4
they really screwed up that one.
someone-noone 08:07 agreed with you
but they're trying to do good things... i guess some day there will be no these problems
linearray 08:07 maybe we will see a final 4.2 when iOS 5 is released
someone-noone 08:07 anyway switching to clang is a good thing, because gcc is quite slow
linearray 08:07 sure
someone-noone 08:07 i will wait for that time :D
arriu 08:07 Is it possible to make firebreath plugins run under a new process? I am relying on a lot of singleton code in my plugin... hitting the reload button or having it open in multiple tabs is causing problems for me
taxilian 08:07 arriu: You can make your own ipc process, but there is no automatic way
Bbl
someone-noone 09:07 taxilian, did you ever faced with "ld: illegal text reloc to non_lazy_ptr " errors?
taxilian 09:07 nope
someone-noone 09:07 seems like i'm the one :D
howdy?
someone-noone 09:07 if i want to add an additional flag to linker\compiler how should i make it correct that after ./prepmac.sh it will not be erased?
in xcode 3
or 4
taxilian 09:07 someone-noone: you'll probably have to modify cmake/buildsettings.cmake
someone-noone 09:07 thanks, i will try that
did you mean buildconfig.cmake?
taxilian 09:07 yeah, that one
someone-noone 10:07 i found there only CMAKE_CFLAGS, but no CMAKE_LDFLAGS or smth like that
taxilian 10:07 C_FLAGS AND CXX_FLAGS
that's compiler
LINK_FLAGS you can set on the project itself
someone-noone 10:07 do you mean projectDef.cmake file? (about LINK_FLAGS)
taxilian 10:07 yeah
someone-noone 10:07 if i understand right i should put 'em into target_link_libraries
taxilian 10:07 wait; you're just trying to add new link libraries?
then yes, that's where they go
someone-noone 10:07 no
i need to add " -read_only_relocs suppress" to my linker
taxilian 10:07 yeah, I don't think that actually works on current versions of xcode
but you can try
!findfile mac.cmake
FireBreathBot 10:07 Found 1 matching file(s) in the master branch. First 1 are:
cmake/Mac.cmake http://goo.gl/LeIEt
taxilian 10:07 look in there; there is a place where we set LINK_FLAGS on the project properties
someone-noone 10:07 thanks
taxilian 10:07 but remember you'll need to get the current ones and add to them
so you don't overwrite them
someone-noone 10:07 WHAT? 0_0
IT'S WORKING!
WOOOOOHOOOOO!
if to add to target_link_libraries it should be done with " symbol
if not to use you will see smth like this: -read_only_relocs -lsuppress
that is not correct
diogopontual 13:07 Hi guys, i'm a firebreath beginner needing some help… There is anybody here that could help me?
sabotaged|wk 14:07 just go ahead and ask. i'm sure someone will answer sooner or later
diogopontual 14:07 ok, thank's
Well, first: I'm using firebreath, so I should help the community to, i'm here to help
second: i have no idea about how i can post a file in firebreath
sabotaged|wk 14:07 you have a bug fix to contribute?
diogopontual 14:07 actually 5 minutes ago was my first contact with the firebreath's jira
i'm reading a bit to understand where i can be helpfull
taxilian 14:07 diogopontual: there is plenty to do; one of the most helpful things is to contribute useful examples and/or documentation to the wiki
what do you mean by "no idea about … post a file in firebreath"? what kind of file? post where?
diogopontual 14:07 sorry, when i sad "in firebreath" i was trying to say "with firebreath", i made a simple plugin that download a remote file, now i need to upload the file :)
taxilian 14:07 unfortunately you can't do that with raw browser APIs
at least that we've discovered
however
there is a class called UploadQueue in a completely undocumented firebreath library called HttpService that can do that
it uses libcurl and openssl
!find UploadQueue
FireBreathBot 14:07 Found 4 possible matches. Displaying 4
/^UploadQueue::UploadQueue( const std::string& _name )$/ (f) found in src/libs/HttpService/HTTPClient/UploadQueue.cpp: http://goo.gl/CBzyB
/^ class UploadQueue : public FB::PluginEventSource {$/ (c) found in src/libs/HttpService/HTTPClient/UploadQueue.h: http://goo.gl/ZbLeP
/^ UploadQueueEntry() : status(ENTRY_WAITING) {}$/ (f) found in src/libs/HttpService/HTTPClient/UploadQueueEntry.h: http://goo.gl/UpekB
/^ typedef boost::shared_ptr<UploadQueue> UploadQueuePtr;$/ (t) found in src/libs/HttpService/HTTPClient/UploadQueue.h: http://goo.gl/ZbLeP
diogopontual 14:07 thank's… i'll study it… maybe it's coming my first contribution :)
jshanab_wcw_ 14:07 I think I have a problem with a library my plugin uses. the dll is also installed by other software and if any have it loaded, the plugin tries to use the loaded dll. (aka dllhell) To solve this I am trying to figure out how to generate a proper manifest. The files created in build\projects\plunname\pluginname.dir that are pluingdname.dll.embed.manifest and pliginname.dll.embed.manifest.res...
...are generated but they have no dependency info. Is this the right way to fix it? and how do I get the Firebreath framework to generate these with dependency info
taxilian 14:07 not a clue...
sabotaged|wk 15:07 what is html logging? i see some methods in browserhost related to that
taxilian 15:07 logging to the js console (firebug, etc)
sabotaged|wk 15:07 oh. it pipes log4cpp to the console?
taxilian 15:07 no
it's a seperate call
I suppose you probably could write something for log4cpp to make it go to that console, but I wouldn't recommend it
VictorAbrash 16:07 I just added my 2nd FB::JSAPIAuto object to my plugin, and I can successfully return it to Javascript as a property of my main plugin object using FB::JSAPIPtr get_Object(). Now I want to be able to send it via an event, ie FB_JSAPI_EVENT(done, 1, (FB::JSAPIPtr object)), which gives me a syntax error. Is this possible, and if yes, how would I declare the event? Thanks.
EL45 17:07 VictorAbrash: I'm not an expert, but wouldn't it be: FB_JSAPI_EVENT(done, 1, (FB::JSAPIPtr));
VictorAbrash 17:07 Thank you! That works, I guess I needed a second pair of eyes....
taxilian 17:07 yeah
one thing, though
you should (practically) never use just FB::JSAPIPtr; instead use const FB::JSAPIPtr&
it is much more efficient, because it prevents it from creating a new copy of the JSAPIPtr and doing refcounting on it
same goes for std::string
when you pass any complex object as an argument into a function, unless you need to change it you should always use const &
VictorAbrash 17:07 OK, using const & works great in the event. What about returning the object from a property or method though? Obviously I can't return a reference to javascript. Right now, I'm defining my object as boost::shared_ptr<MyObject> myObject(boost::make_shared<MyObject>(objectArgs)) and either returning that directly (as a const property) or as an argument to my event (using const &).
taxilian 17:07 you can't return references
that only applies to when you are passing as an argument to a function
and that should work fine for the return value; however, you can also use the FB_FORWARD_PTR macro to define typedefs for MyObjectPtr and MyObjectWeakPtr
VictorAbrash 17:07 I actually already have those two defined (eg, as typedef boost::shared_ptr<MyObject> MyObjectPtr), just wanted to be more explicit in the question.
taxilian 17:07 and I was just making sure you know you don't have to define them yourself, you can use FB_FORWARD_PTR =]
brb
VictorAbrash 17:07 But the macro looks like a better way to define them. Thanks for the pointer.
Feeling 18:07 does anyone know for chome drag & drop?
chrome