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

Changes to allow build on FreeBSD #1460

Merged
merged 9 commits into from
Aug 13, 2018
Merged

Conversation

RenZ0
Copy link
Contributor

@RenZ0 RenZ0 commented Aug 8, 2018

No description provided.

@peternewman
Copy link
Member

Based on #1456 .

The first commit is for FreeBSD 10 (old one).
The second one is for FreeBSD 10.4 and 11.2, work in progress.

@@ -6,5 +6,6 @@ noinst_LTLIBRARIES += common/testing/libolatesting.la \
common_testing_libolatesting_la_SOURCES = \
common/testing/MockUDPSocket.cpp \
common/testing/TestUtils.cpp
common_testing_libolatesting_la_CXXFLAGS = $(COMMON_TESTING_PROTOBUF_FLAGS)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need @RenZ0 to check the exact message you were getting for this please and I'll see if we can use a more bespoke and appropriate set of flags? This will be in some time when he can restart the machine again.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is on FreeBSD 10.0-RELEASE. I can't reproduce that, I guess I had the message because I started from the release and I didn't run autoreconf. So this change is not needed.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, yeah great, lets revert this change then.

@peternewman peternewman self-assigned this Aug 8, 2018
@peternewman peternewman added this to the 0.10.8 milestone Aug 8, 2018
@peternewman
Copy link
Member

Also blocked by upstream https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=230282 .

@peternewman
Copy link
Member

The upstream bug has now been merged!

@RenZ0
Copy link
Contributor Author

RenZ0 commented Aug 11, 2018

Tests are now fixed as well.

@@ -110,7 +110,11 @@ TCPSocket *ConnectToServer(unsigned short port) {
// Try to start the server, we pass --daemon (fork into background) and
// --syslog (log to syslog).
execlp("olad", "olad", "--daemon", "--syslog",
reinterpret_cast<char*>(NULL));
#ifdef __FreeBSD__
reinterpret_cast<char*>(0));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we align this, and the line below with the ( above please.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, with some more occurences :)

@RenZ0
Copy link
Contributor Author

RenZ0 commented Aug 12, 2018

Indentation should be proper now.

Copy link
Member

@peternewman peternewman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. So this now builds correctly on FreeBSD 10.0/10.4 and 11 (aside from the ThreadTester failure)?

It's probably worth updating NEWS with this fact too.

@@ -226,7 +226,7 @@ vector<Interface> PosixInterfacePicker::GetInterfaces(
interface.index = ifrcopy.ifr_index;
#else
interface.index = ifrcopy.ifr_ifindex;
#endif // SIOCGIFINDEX
#endif // __FreeBSD__
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good spot!

@peternewman peternewman assigned nomis52 and unassigned peternewman Aug 12, 2018
@peternewman
Copy link
Member

Blocked behind #1464

@RenZ0
Copy link
Contributor Author

RenZ0 commented Aug 12, 2018

Also we may precise in NEWS that 10.0 needs --disable-fatal-warnings, because of error: unused parameter 'e' [-Werror,-Wunused-parameter], which seems to be an upstream cppunit header error.

@peternewman
Copy link
Member

You could do @RenZ0 , but given it's unsupported it's probably not worth it.

@peternewman peternewman merged commit e1e8620 into OpenLightingProject:0.10 Aug 13, 2018
@neheb
Copy link

neheb commented Apr 13, 2022

Same issue on musl 1.2.3 as well. Why not just make it 0 everywhere?

@peternewman
Copy link
Member

Same issue on musl 1.2.3 as well. Why not just make it 0 everywhere?

Followed up in #1773 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants