Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add workaround to issue in conan's GLOG build/link process for windows #20

Open
ShamanTcler opened this issue Aug 12, 2020 · 3 comments
Assignees
Labels
question Further information is requested

Comments

@ShamanTcler
Copy link

[==========] 14 tests from 1 test suite ran. (98439 ms total)
[ PASSED ] 14 tests.

This was built with Win 10 MSVS 2015.

The current issue is with GLOG this is the bug report: conan-io/conan-center-index#2494

I stubbed in "Spacelm" suggestion of:

#ifdef _WIN32
#ifndef MINGW32
#define GOOGLE_GLOG_DLL_DECL
#endif
#endif

( don't you just love those little magic incantations .... sigh)

before every glog include ... and she built.

My suggestion is make no changes just wait for that bug fix and rebuild.

Thanks and regards
Carl

@ShamanTcler ShamanTcler changed the title Windows, a long said tail of whoa .... but it WORKS! :) Windows, a long said tale of whoa .... but it WORKS! :) Aug 12, 2020
@thclark
Copy link
Owner

thclark commented Aug 12, 2020

Thanks for all your work, @ShamanTcler / Carl!

(I'm Tom, by the way ;) !).

The current issue is with GLOG this is the bug report: conan-io/conan-center-index#2494

I stubbed in "Spacelm" suggestion of:

#ifdef _WIN32
#ifndef MINGW32
#define GOOGLE_GLOG_DLL_DECL
#endif
#endif

Is this something you've subbed into the cpplot codebase? Or into somewhere else?

@thclark thclark self-assigned this Aug 12, 2020
@thclark thclark added the question Further information is requested label Aug 12, 2020
@ShamanTcler
Copy link
Author

To get mine to work I edited my local copies .... i.e.

cpplot_test.cpp now has this snippet:

#include "eigen.h"
#include "exceptions.h"
#include "gtest/gtest.h"
#ifdef _WIN32
#ifndef __MINGW32__
#define GOOGLE_GLOG_DLL_DECL 
#endif
#endif
#include "glog/logging.h"

I would not make these changes to the code.

Let them fix Conan's GLOG and things should work fine. Just curious was the test code supposed to echo tons of data to the screen?

here is the output of the test app:

-rwx------+ 1 210008258 Domain Users      399 Aug 12 10:30 test_3d_axes_labels.json
-rwx------+ 1 210008258 Domain Users      196 Aug 12 10:29 test_bar_and_scatter_plot.json
-rwx------+ 1 210008258 Domain Users      153 Aug 12 10:29 test_bar_plot.json
-rwx------+ 1 210008258 Domain Users      225 Aug 12 10:30 test_latex_labels.json
-rwx------+ 1 210008258 Domain Users      172 Aug 12 10:30 test_layout_no_title_plot.json
-rwx------+ 1 210008258 Domain Users      194 Aug 12 10:30 test_layout_plot.json
-rwx------+ 1 210008258 Domain Users     3381 Aug 12 10:30 test_log_axes.json
-rwx------+ 1 210008258 Domain Users 14094026 Aug 12 10:29 test_mandelbrot_plot.json
-rwx------+ 1 210008258 Domain Users      124 Aug 12 10:29 test_scatter_plot.json
-rwx------+ 1 210008258 Domain Users      216 Aug 12 10:29 test_scatter_with_legend_plot.json
-rwx------+ 1 210008258 Domain Users      294 Aug 12 10:29 test_surface_plot.json
-rwx------+ 1 210008258 Domain Users      175 Aug 12 10:29 test_wide_coloured_dashed_scatter_plot.json
-rwx------+ 1 210008258 Domain Users     1919 Aug 12 10:30 test_wolfgang.json

My intent is to build this with MSVS 2015/2017/2019 so it should get exercised.

@thclark
Copy link
Owner

thclark commented Aug 12, 2020

I would not make these changes to the code.

Why not? I can make the fix, and add a TODO to clear it up once conan's glog is fixed (unlikely to be any time soon).

Just curious was the test code supposed to echo tons of data to the screen?

I can't remember, but probably, as I was nervously printing everything I could get my hands on. I'll consider suppressing the output during test.

@thclark thclark changed the title Windows, a long said tale of whoa .... but it WORKS! :) Add workaround to issue in conan's GLOG build/link process for windows Aug 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants