Abhishek's "refactoring" (r9946) makes things much worse
Hello
The object of the C++ refactoring GSoC project by Abhishek was to better separate the object tree (interpretation) and the XML tree (representation). But the recent merge of his work made it clear that he potentially made things much worse!
Abhishek's patch introduces these functions:
void attach(SPObject *object, SPObject *prev); void reorder(SPObject *prev); void detach(SPObject *object); long long int getIntAttribute(char const *key, long long int def); unsigned getPosition(); gchar const * getAttribute(gchar const *name,SPException *ex=0) const; void appendChild(Inkscape::XML::Node *child); void addChild(Inkscape::XML::Node *child,Inkscape::XML::Node *prev=0); void setKeyValue(unsigned int key, gchar const *value); void setAttribute(gchar const *key, gchar const *value, SPException *ex=0); void readAttr(gchar const *key); void removeAttribute(gchar const *key, SPException *ex=0); bool storeAsDouble( gchar const *key, double *val ) const;
All of those are public and operate directly on the XML tree - exactly the type of operation that the project was supposed to reduce!
What do we do now? At the least, all the functions listed above should be made private.
Regards, Krzysztof
Additionally, there's a critical bug. The open dialog hangs Inkscape for me (no crash, just an empty dialog with a gray background and the main window becomes unresponsive) since 9946. The result is that I can only open files from the file manager or via the command line. I'm on Ubuntu 10.10.
Regards, Krzysztof
On Dec 12, 2010, at 4:53 AM, Krzysztof Kosiński wrote:
Hello
The object of the C++ refactoring GSoC project by Abhishek was to better separate the object tree (interpretation) and the XML tree (representation). But the recent merge of his work made it clear that he potentially made things much worse!
[SNIP]
All of those are public and operate directly on the XML tree - exactly the type of operation that the project was supposed to reduce!
What do we do now? At the least, all the functions listed above should be made private.
Well, then start looking at things to make them private/protected in the *proper* way.
First of all, the main objective of the project was not to separate the XML tree. The main goal was to make progress on cleaning up our structure into C++ instead of legacy C that we had. There was a huge amount of work done on that.
A *secondary* goal was to work on abstracting the XML tree. Given the bad state that our source code was in, it was understood from the begining that complete separation could not be achieved.
*However* one of the things it was doing was changing to make the access more explicit. Aside from arranging code into classes instead of just a random collection of functions (sometimes spread over many source files), the access of data was clarified somewhat. Now that we do have such clearly improper access methods, work can be done to cleanly abstract them. It's a very simple matter to add a deprecated attribute to those methods one-by-one and have the compiler guide you to all the places to look.
To summarize what you should be able to see, we had bad access all over the place before the refactoring; now, however, some of it is more explicit and easier to spot and thus will be easier to fix.
W dniu 12 grudnia 2010 18:25 użytkownik Jon Cruz <jon@...18...> napisał:
To summarize what you should be able to see, we had bad access all over the place before the refactoring; now, however, some of it is more explicit and easier to spot and thus will be easier to fix.
Okay, this does make some sense. However, I would like to see those methods marked with a warning saying that they should not be used outside of the SP tree.
Regards, Krzysztof
On Dec 12, 2010, at 2:38 PM, Krzysztof Kosiński wrote:
W dniu 12 grudnia 2010 18:25 użytkownik Jon Cruz <jon@...18...> napisał:
To summarize what you should be able to see, we had bad access all over the place before the refactoring; now, however, some of it is more explicit and easier to spot and thus will be easier to fix.
Okay, this does make some sense. However, I would like to see those methods marked with a warning saying that they should not be used outside of the SP tree.
Yes, you can add TODO comments if you want. That would be helpful.
But what would be most helpful is looking over to figure out the clean ways to change the code so that such access is no longer exposed to begin with. Comments and warnings can often be ignored over time. Our bounding box functions are a good example. They had been deprecated, but people still have not stepped up to help clean up the use.
W dniu 12 grudnia 2010 23:42 użytkownik Jon Cruz <jon@...18...> napisał:
But what would be most helpful is looking over to figure out the clean ways to change the code so that such access is no longer exposed to begin with.
Off the top of my head, the largest problem is that there is no way to create a specific SPObject and add it to the tree. We need to create an XML representation of this object, insert it into the XML tree and rely on the XML tree observers to automatically create the corresponding SPObject for us. Therefore each of the shape tools needs to know how its products are represented in SVG markup, while in the ideal situation only the given shape's SPObject implementation should know this. Solving this would go 90% of the way towards making XML private.
Regards, Krzysztof
On Dec 12, 2010, at 2:49 PM, Krzysztof Kosiński wrote:
W dniu 12 grudnia 2010 23:42 użytkownik Jon Cruz <jon@...18...> napisał:
But what would be most helpful is looking over to figure out the clean ways to change the code so that such access is no longer exposed to begin with.
Off the top of my head, the largest problem is that there is no way to create a specific SPObject and add it to the tree. We need to create an XML representation of this object, insert it into the XML tree and rely on the XML tree observers to automatically create the corresponding SPObject for us. Therefore each of the shape tools needs to know how its products are represented in SVG markup, while in the ideal situation only the given shape's SPObject implementation should know this. Solving this would go 90% of the way towards making XML private.
You should run a review of that change. Among other things, some of the classes were fixed to abstract exactly that sort of tool construction needs. (yes, it is a large change so I understand that it is especially easy to miss some of the big-picture issues it addressed)
For example, things were refactored so that the tool for a 3d box did not have to know all about the XML used to create such a box, or even that such a box representation uses XML to begin with.
+ + /** + * Create a SPBox3D and append it to the parent. + */ + static SPBox3D * createBox3D(SPItem * parent); };
But I do agree. That is exactly the sort of encapsulation we need to continue working towards. Abhishek was able to start that with some classes, but there are still many more that need similar cleanup.
Maybe related to this "refactoring": can't compile under Windows XP anymore. Thanks for taking a look at this. Luca
Make error line 299: problem compiling: In file included from ./src/color-profile.h:12, from ./src/color-profile-test.h:11, from src/test-src.cpp:27: c:\devlibs/include/lcms.h: In function 'void* _cmsMalloc(size_t)': c:\devlibs/include/lcms.h:1410: warning: comparison of unsigned expression < 0 is always false In file included from src/test-src.cpp:184: ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testWrite()': ./src/sp-style-elem-test.h:76: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:77: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:85: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testBuild()': ./src/sp-style-elem-test.h:102: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:103: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:108: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testReadContent()': ./src/sp-style-elem-test.h:130: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:131: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:136: error: 'sp_document_repr_doc' was not declared in this scope
Make error line 299: problem compiling: src/extension/internal/emf-win32-inout.cpp: In function 'void Inkscape::Extension::Internal::emf_print_document_to_file(SPDocument*, const gchar*)': src/extension/internal/emf-win32-inout.cpp:127: error: 'sp_item_display_key_new' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:128: error: 'sp_item_invoke_show' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:135: error: 'sp_item_invoke_print' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:138: error: 'sp_item_invoke_hide' was not declared in this scope
Make error line 299: problem compiling: src/extension/internal/emf-win32-print.cpp: In member function 'virtual unsigned int Inkscape::Extension::Internal::PrintEmfWin32::begin(Inkscape::Extension::Print*, SPDocument*)': src/extension/internal/emf-win32-print.cpp:152: error: 'sp_item_invoke_bbox' was not declared in this scope
Make error line 299: problem compiling: src/jabber_whiteboard/dialog/choose-desktop.cpp:33: warning: unused parameter 'path' src/jabber_whiteboard/dialog/choose-desktop.cpp:33: warning: unused parameter 'col' src/document.h: In member function 'bool Inkscape::Whiteboard::ChooseDesktop::doSetup()': src/document.h:99: error: 'gchar* SPDocument::name' is protected src/jabber_whiteboard/dialog/choose-desktop.cpp:74: error: within this context
Make error line 299: problem compiling: src/ui/dialog/filedialogimpl-win32.cpp: In member function 'bool Inkscape::UI::Dialog::FileOpenDialogImplWin32::set_svg_preview()': src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected type-specifier before '(' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected '>' before '(' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected primary-expression before '*' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected primary-expression before ')' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: 'class SPObject' has no member named 'invoke_bbox' src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected type-specifier before '(' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected '>' before '(' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected primary-expression before '*' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected primary-expression before ')' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: 'class SPObject' has no member named 'i2d_affine' src/ui/dialog/filedialogimpl-win32.cpp:946: error: 'sp_item_display_key_new' was not declared in this scope src/ui/dialog/filedialogimpl-win32.cpp:949: error: 'sp_item_invoke_show' was not declared in this scope src/ui/dialog/filedialogimpl-win32.cpp:985: error: 'sp_item_invoke_hide' was not declared in this scope
I realized that AGAIN I didn't respond to the list... (sure my phone's gmail app can now default to "reply all" but not gmail itself... that I know of but will now look for)
Will someone on win32 please try with a btool clean to see if it builds okay? This was one of the issues I remember from win32 compiling that drove me nuts.
Cheers, Josh
On Mon, Dec 13, 2010 at 9:19 AM, LucaDC <dicappello@...2144...> wrote:
Maybe related to this "refactoring": can't compile under Windows XP anymore. Thanks for taking a look at this. Luca
Make error line 299: problem compiling: In file included from ./src/color-profile.h:12, from ./src/color-profile-test.h:11, from src/test-src.cpp:27: c:\devlibs/include/lcms.h: In function 'void* _cmsMalloc(size_t)': c:\devlibs/include/lcms.h:1410: warning: comparison of unsigned expression < 0 is always false In file included from src/test-src.cpp:184: ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testWrite()': ./src/sp-style-elem-test.h:76: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:77: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:85: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testBuild()': ./src/sp-style-elem-test.h:102: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:103: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:108: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testReadContent()': ./src/sp-style-elem-test.h:130: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:131: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:136: error: 'sp_document_repr_doc' was not declared in this scope
Make error line 299: problem compiling: src/extension/internal/emf-win32-inout.cpp: In function 'void Inkscape::Extension::Internal::emf_print_document_to_file(SPDocument*, const gchar*)': src/extension/internal/emf-win32-inout.cpp:127: error: 'sp_item_display_key_new' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:128: error: 'sp_item_invoke_show' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:135: error: 'sp_item_invoke_print' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:138: error: 'sp_item_invoke_hide' was not declared in this scope
Make error line 299: problem compiling: src/extension/internal/emf-win32-print.cpp: In member function 'virtual unsigned int Inkscape::Extension::Internal::PrintEmfWin32::begin(Inkscape::Extension::Print*, SPDocument*)': src/extension/internal/emf-win32-print.cpp:152: error: 'sp_item_invoke_bbox' was not declared in this scope
Make error line 299: problem compiling: src/jabber_whiteboard/dialog/choose-desktop.cpp:33: warning: unused parameter 'path' src/jabber_whiteboard/dialog/choose-desktop.cpp:33: warning: unused parameter 'col' src/document.h: In member function 'bool Inkscape::Whiteboard::ChooseDesktop::doSetup()': src/document.h:99: error: 'gchar* SPDocument::name' is protected src/jabber_whiteboard/dialog/choose-desktop.cpp:74: error: within this context
Make error line 299: problem compiling: src/ui/dialog/filedialogimpl-win32.cpp: In member function 'bool Inkscape::UI::Dialog::FileOpenDialogImplWin32::set_svg_preview()': src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected type-specifier before '(' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected '>' before '(' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected primary-expression before '*' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected primary-expression before ')' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: 'class SPObject' has no member named 'invoke_bbox' src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected type-specifier before '(' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected '>' before '(' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected primary-expression before '*' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected primary-expression before ')' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: 'class SPObject' has no member named 'i2d_affine' src/ui/dialog/filedialogimpl-win32.cpp:946: error: 'sp_item_display_key_new' was not declared in this scope src/ui/dialog/filedialogimpl-win32.cpp:949: error: 'sp_item_invoke_show' was not declared in this scope src/ui/dialog/filedialogimpl-win32.cpp:985: error: 'sp_item_invoke_hide' was not declared in this scope
-- View this message in context: http://old.nabble.com/Abhishek%27s-%22refactoring%22-%28r9946%29-makes-thing... Sent from the Inkscape - Dev mailing list archive at Nabble.com.
Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
Woohoo found it in Labs... just so anyone else who was wondering knows. ;)
On Mon, Dec 13, 2010 at 8:42 PM, Josh Andler <scislac@...400...> wrote:
I realized that AGAIN I didn't respond to the list... (sure my phone's gmail app can now default to "reply all" but not gmail itself... that I know of but will now look for)
Will someone on win32 please try with a btool clean to see if it builds okay? This was one of the issues I remember from win32 compiling that drove me nuts.
Cheers, Josh
On Mon, Dec 13, 2010 at 9:19 AM, LucaDC <dicappello@...2144...> wrote:
Maybe related to this "refactoring": can't compile under Windows XP anymore. Thanks for taking a look at this. Luca
Make error line 299: problem compiling: In file included from ./src/color-profile.h:12, from ./src/color-profile-test.h:11, from src/test-src.cpp:27: c:\devlibs/include/lcms.h: In function 'void* _cmsMalloc(size_t)': c:\devlibs/include/lcms.h:1410: warning: comparison of unsigned expression < 0 is always false In file included from src/test-src.cpp:184: ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testWrite()': ./src/sp-style-elem-test.h:76: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:77: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:85: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testBuild()': ./src/sp-style-elem-test.h:102: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:103: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:108: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testReadContent()': ./src/sp-style-elem-test.h:130: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:131: error: 'sp_document_repr_doc' was not declared in this scope ./src/sp-style-elem-test.h:136: error: 'sp_document_repr_doc' was not declared in this scope
Make error line 299: problem compiling: src/extension/internal/emf-win32-inout.cpp: In function 'void Inkscape::Extension::Internal::emf_print_document_to_file(SPDocument*, const gchar*)': src/extension/internal/emf-win32-inout.cpp:127: error: 'sp_item_display_key_new' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:128: error: 'sp_item_invoke_show' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:135: error: 'sp_item_invoke_print' was not declared in this scope src/extension/internal/emf-win32-inout.cpp:138: error: 'sp_item_invoke_hide' was not declared in this scope
Make error line 299: problem compiling: src/extension/internal/emf-win32-print.cpp: In member function 'virtual unsigned int Inkscape::Extension::Internal::PrintEmfWin32::begin(Inkscape::Extension::Print*, SPDocument*)': src/extension/internal/emf-win32-print.cpp:152: error: 'sp_item_invoke_bbox' was not declared in this scope
Make error line 299: problem compiling: src/jabber_whiteboard/dialog/choose-desktop.cpp:33: warning: unused parameter 'path' src/jabber_whiteboard/dialog/choose-desktop.cpp:33: warning: unused parameter 'col' src/document.h: In member function 'bool Inkscape::Whiteboard::ChooseDesktop::doSetup()': src/document.h:99: error: 'gchar* SPDocument::name' is protected src/jabber_whiteboard/dialog/choose-desktop.cpp:74: error: within this context
Make error line 299: problem compiling: src/ui/dialog/filedialogimpl-win32.cpp: In member function 'bool Inkscape::UI::Dialog::FileOpenDialogImplWin32::set_svg_preview()': src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected type-specifier before '(' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected '>' before '(' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected primary-expression before '*' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: expected primary-expression before ')' token src/ui/dialog/filedialogimpl-win32.cpp:941: error: 'class SPObject' has no member named 'invoke_bbox' src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected type-specifier before '(' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected '>' before '(' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected primary-expression before '*' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: expected primary-expression before ')' token src/ui/dialog/filedialogimpl-win32.cpp:942: error: 'class SPObject' has no member named 'i2d_affine' src/ui/dialog/filedialogimpl-win32.cpp:946: error: 'sp_item_display_key_new' was not declared in this scope src/ui/dialog/filedialogimpl-win32.cpp:949: error: 'sp_item_invoke_show' was not declared in this scope src/ui/dialog/filedialogimpl-win32.cpp:985: error: 'sp_item_invoke_hide' was not declared in this scope
-- View this message in context: http://old.nabble.com/Abhishek%27s-%22refactoring%22-%28r9946%29-makes-thing... Sent from the Inkscape - Dev mailing list archive at Nabble.com.
Lotusphere 2011 Register now for Lotusphere 2011 and learn how to connect the dots, take your collaborative environment to the next level, and enter the era of Social Business. http://p.sf.net/sfu/lotusphere-d2d _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
2010/12/14 Josh Andler <scislac@...400...>:
I realized that AGAIN I didn't respond to the list... (sure my phone's gmail app can now default to "reply all" but not gmail itself... that I know of but will now look for)
Will someone on win32 please try with a btool clean to see if it builds okay? This was one of the issues I remember from win32 compiling that drove me nuts.
Inkscape still does not compile, for reasons that have been mentioned before. AFAIK the discussion on upgrading the requirements for building inkscape has not resulted in a clear decision.
Regards Kris
--- The first error (when compiling /src/desktop.cpp): Make error line 299: problem compiling: In file included from c:\devlibs/include /boost/mpl/apply.hpp:23:0, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply_wrap.hpp:81:31: error: missing binary operato r before token "(" c:\devlibs/include/boost/mpl/apply_wrap.hpp:173:31: error: missing binary operat or before token "(" In file included from c:\devlibs/include/boost/mpl/bind.hpp:27:0, from c:\devlibs/include/boost/mpl/lambda.hpp:18, from c:\devlibs/include/boost/mpl/apply.hpp:25, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply_wrap.hpp:81:31: error: missing binary operato r before token "(" c:\devlibs/include/boost/mpl/apply_wrap.hpp:173:31: error: missing binary operat or before token "(" In file included from c:\devlibs/include/boost/mpl/lambda.hpp:18:0, from c:\devlibs/include/boost/mpl/apply.hpp:25, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/bind.hpp:364:31: error: missing binary operator bef ore token "(" c:\devlibs/include/boost/mpl/bind.hpp:531:31: error: missing binary operator bef ore token "(" In file included from c:\devlibs/include/boost/mpl/lambda.hpp:22:0, from c:\devlibs/include/boost/mpl/apply.hpp:25, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/aux_/full_lambda.hpp:230:31: error: missing binary operator before token "(" In file included from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34:0 , from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply.hpp:138:31: error: missing binary operator be fore token "(" In file included from src/2geom/d2.h:36:0, from src/2geom/rect.h:40, from src/desktop.cpp:60: src/2geom/interval.h: In member function 'bool Geom::OptInterval::isEmpty()': src/2geom/interval.h:241:46: warning: converting 'false' to pointer type for arg ument 2 of 'bool boost::operator==(const boost::optional<T>&, void (*)(boost::de tail::none_helper)) [with T = Geom::Interval, void (*)(boost::detail::none_helpe r) = void (*)(boost::detail::none_helper)]' In file included from src/2geom/d2.h:429:0, from src/2geom/rect.h:40, from src/desktop.cpp:60: src/2geom/rect.h: In member function 'bool Geom::OptRect::isEmpty() const': src/2geom/rect.h:218:52: warning: converting 'false' to pointer type for argumen t 2 of 'bool boost::operator==(const boost::optional<T>&, void (*)(boost::detail ::none_helper)) [with T = Geom::D2Geom::Interval, void (*)(boost::detail::none _helper) = void (*)(boost::detail::none_helper)]' In file included from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19:0, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/ptr_container/detail/map_iterator.hpp: At global scope:
c:\devlibs/include/boost/ptr_container/detail/map_iterator.hpp:46:48: warning: t ype qualifiers ignored on function return type
PS: I also encounter the errors Luca mentioned
2010/12/14 Kris De Gussem <kris.degussem@...400...>:
2010/12/14 Josh Andler <scislac@...400...>:
I realized that AGAIN I didn't respond to the list... (sure my phone's gmail app can now default to "reply all" but not gmail itself... that I know of but will now look for)
Will someone on win32 please try with a btool clean to see if it builds okay? This was one of the issues I remember from win32 compiling that drove me nuts.
Inkscape still does not compile, for reasons that have been mentioned before. AFAIK the discussion on upgrading the requirements for building inkscape has not resulted in a clear decision.
Regards Kris
The first error (when compiling /src/desktop.cpp): Make error line 299: problem compiling: In file included from c:\devlibs/include /boost/mpl/apply.hpp:23:0, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply_wrap.hpp:81:31: error: missing binary operato r before token "(" c:\devlibs/include/boost/mpl/apply_wrap.hpp:173:31: error: missing binary operat or before token "(" In file included from c:\devlibs/include/boost/mpl/bind.hpp:27:0, from c:\devlibs/include/boost/mpl/lambda.hpp:18, from c:\devlibs/include/boost/mpl/apply.hpp:25, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply_wrap.hpp:81:31: error: missing binary operato r before token "(" c:\devlibs/include/boost/mpl/apply_wrap.hpp:173:31: error: missing binary operat or before token "(" In file included from c:\devlibs/include/boost/mpl/lambda.hpp:18:0, from c:\devlibs/include/boost/mpl/apply.hpp:25, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/bind.hpp:364:31: error: missing binary operator bef ore token "(" c:\devlibs/include/boost/mpl/bind.hpp:531:31: error: missing binary operator bef ore token "(" In file included from c:\devlibs/include/boost/mpl/lambda.hpp:22:0, from c:\devlibs/include/boost/mpl/apply.hpp:25, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/aux_/full_lambda.hpp:230:31: error: missing binary operator before token "(" In file included from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34:0 , from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply.hpp:138:31: error: missing binary operator be fore token "(" In file included from src/2geom/d2.h:36:0, from src/2geom/rect.h:40, from src/desktop.cpp:60: src/2geom/interval.h: In member function 'bool Geom::OptInterval::isEmpty()': src/2geom/interval.h:241:46: warning: converting 'false' to pointer type for arg ument 2 of 'bool boost::operator==(const boost::optional<T>&, void (*)(boost::de tail::none_helper)) [with T = Geom::Interval, void (*)(boost::detail::none_helpe r) = void (*)(boost::detail::none_helper)]' In file included from src/2geom/d2.h:429:0, from src/2geom/rect.h:40, from src/desktop.cpp:60: src/2geom/rect.h: In member function 'bool Geom::OptRect::isEmpty() const': src/2geom/rect.h:218:52: warning: converting 'false' to pointer type for argumen t 2 of 'bool boost::operator==(const boost::optional<T>&, void (*)(boost::detail ::none_helper)) [with T = Geom::D2Geom::Interval, void (*)(boost::detail::none _helper) = void (*)(boost::detail::none_helper)]' In file included from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19:0, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/ptr_container/detail/map_iterator.hpp: At global scope:
c:\devlibs/include/boost/ptr_container/detail/map_iterator.hpp:46:48: warning: t ype qualifiers ignored on function return type
On Dec 13, 2010, at 11:31 PM, Kris De Gussem wrote:
Inkscape still does not compile, for reasons that have been mentioned before. AFAIK the discussion on upgrading the requirements for building inkscape has not resulted in a clear decision.
Regards Kris
The first error (when compiling /src/desktop.cpp): Make error line 299: problem compiling: In file included from c:\devlibs/include /boost/mpl/apply.hpp:23:0, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
Those should have been fixed. I'm waiting to hear back on which version of BOOST updated the thing we need fixed, but the devlibs should have been bumped to a very recent version a while back.
2010/12/14 Kris De Gussem <kris.degussem@...400...>:
Inkscape still does not compile, for reasons that have been mentioned before. AFAIK the discussion on upgrading the requirements for building inkscape has not resulted in a clear decision.
Regards Kris
The first error (when compiling /src/desktop.cpp): Make error line 299: problem compiling: In file included from c:\devlibs/include /boost/mpl/apply.hpp:23:0, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply_wrap.hpp:81:31: error: missing binary operato r before token "(" c:\devlibs/include/boost/mpl/apply_wrap.hpp:173:31: error: missing binary operat or before token "("
Please verify which version of Devlibs you have. This particular type of compile error should be fixed in revision 20 due to Boost update (to 1.44.0). However, the errors in filedialogimpl-win32.cpp have nothing to do with boost and were introduced by the merge.
Regards, Krzysztof
Sorry, did not do a reply all yesterday:
"It appears that during the latest update of the devlibs on my local PC, not everything was downloaded. Removing and checking out the devlibs solved the BOOST issue."
So when upating devlibs to revision 20 one month ago a.o. the directory accumulators of the include files was not downloaded to my PC (problem with bzr? something else? Do not know...).
Regards Kris
2010/12/14 Krzysztof Kosiński <tweenk.pl@...400...>:
2010/12/14 Kris De Gussem <kris.degussem@...400...>:
Inkscape still does not compile, for reasons that have been mentioned before. AFAIK the discussion on upgrading the requirements for building inkscape has not resulted in a clear decision.
Regards Kris
The first error (when compiling /src/desktop.cpp): Make error line 299: problem compiling: In file included from c:\devlibs/include /boost/mpl/apply.hpp:23:0, from c:\devlibs/include/boost/iterator/iterator_facade.hpp:34, from c:\devlibs/include/boost/iterator/iterator_adaptor.hpp:15,
from c:\devlibs/include/boost/ptr_container/detail/map_iterator .hpp:20, from c:\devlibs/include/boost/ptr_container/ptr_map_adapter.hpp :19, from c:\devlibs/include/boost/ptr_container/ptr_map.hpp:20, from src/ui/tool/node-tool.h:15, from src/desktop.cpp:96: c:\devlibs/include/boost/mpl/apply_wrap.hpp:81:31: error: missing binary operato r before token "(" c:\devlibs/include/boost/mpl/apply_wrap.hpp:173:31: error: missing binary operat or before token "("
Please verify which version of Devlibs you have. This particular type of compile error should be fixed in revision 20 due to Boost update (to 1.44.0). However, the errors in filedialogimpl-win32.cpp have nothing to do with boost and were introduced by the merge.
Regards, Krzysztof
Josh Andler wrote:
Will someone on win32 please try with a btool clean to see if it builds okay? This was one of the issues I remember from win32 compiling that drove me nuts.
Of course I did. I always do a clean build before reporting an issue. Regards. Luca
On Dec 13, 2010, at 9:19 AM, LucaDC wrote:
Maybe related to this "refactoring": can't compile under Windows XP anymore. Thanks for taking a look at this. Luca
Make error line 299: problem compiling: In file included from ./src/color-profile.h:12, from ./src/color-profile-test.h:11, from src/test-src.cpp:27: c:\devlibs/include/lcms.h: In function 'void* _cmsMalloc(size_t)': c:\devlibs/include/lcms.h:1410: warning: comparison of unsigned expression < 0 is always false In file included from src/test-src.cpp:184: ./src/sp-style-elem-test.h: In member function 'void SPStyleElemTest::testWrite()': ./src/sp-style-elem-test.h:76: error: 'sp_document_repr_doc' was not declared in this scope
Uh oh!!!!
It appears that I did not run a "make check" on the latest merging. Should be resolved fairly soon.
On Dec 13, 2010, at 9:19 AM, LucaDC wrote:
Maybe related to this "refactoring": can't compile under Windows XP anymore. Thanks for taking a look at this. Luca
Make error line 299: problem compiling: In file included from ./src/color-profile.h:12, from ./src/color-profile-test.h:11,
Round of fixes in revision 9953.
They may allow other files to compile and reveal more bugs, or it might be fixed. Please test and let us know.
Jon Cruz wrote:
Round of fixes in revision 9953.
They may allow other files to compile and reveal more bugs, or it might be fixed. Please test and let us know.
Much better, thanks. But not enough. I still get this error. Luca
Make error line 299: problem compiling: src/extension/internal/emf-win32-inout.cpp: In function 'void Inkscape::Extension::Internal::emf_print_document_to_file(SPDocument*, const gchar*)': src/extension/internal/emf-win32-inout.cpp:127: error: 'sp_item_display_key_new' was not declared in this scope
Quoting LucaDC <dicappello@...2144...>:
Jon Cruz wrote:
Round of fixes in revision 9953.
They may allow other files to compile and reveal more bugs, or it might be fixed. Please test and let us know.
Much better, thanks. But not enough. I still get this error. Luca
Make error line 299: problem compiling: src/extension/internal/emf-win32-inout.cpp: In function 'void Inkscape::Extension::Internal::emf_print_document_to_file(SPDocument*, const gchar*)': src/extension/internal/emf-win32-inout.cpp:127: error: 'sp_item_display_key_new' was not declared in this scope
Drat. I accidentally did an undo on that line, but got the others in. The fix for line 127 should be
mod->dkey = SPItem::display_key_new(1);
I'd commit a fix myself, but I'm at a wifi spot that only allows web access.
Jon Cruz wrote:
Drat. I accidentally did an undo on that line, but got the others in. The fix for line 127 should be
mod->dkey = SPItem::display_key_new(1);
I'd commit a fix myself, but I'm at a wifi spot that only allows web access.
I managed to compile again with this last modification. Thanks. I hope it will be committed soon. Luca
participants (6)
-
unknown@example.com
-
Jon Cruz
-
Josh Andler
-
Kris De Gussem
-
Krzysztof Kosiński
-
LucaDC