Git Product home page Git Product logo

Comments (10)

0xFFFC0000 avatar 0xFFFC0000 commented on July 20, 2024 2
if(NOT MSVC)              
  add_compile_options(-D_GNU_SOURCE)
endif()

Fixed the issue. Now we have updated miniupnpc and fixed this compilation issue.

from monero.

SyntheticBird45 avatar SyntheticBird45 commented on July 20, 2024 1

@0xFFFC0000 testing

from monero.

SyntheticBird45 avatar SyntheticBird45 commented on July 20, 2024

Confirm, same issue on updated Arch Linux

from monero.

SyntheticBird45 avatar SyntheticBird45 commented on July 20, 2024

@selsta Applied pastebin modifications.
Failed at 24%:

[scrubbed]/monero/external/miniupnp/miniupnpc/src/minihttptestserver.c:299:25: error: implicit declaration of function 'usleep'; did you mean 'sleep'? [-Wimplicit-function-declaration]
  299 |                         usleep(10000); /* 10ms */
      |                         ^~~~~~
      |                         sleep
make[2]: *** [external/miniupnp/miniupnpc/CMakeFiles/minihttptestserver.dir/build.make:76: external/miniupnp/miniupnpc/CMakeFiles/minihttptestserver.dir/src/minihttptestserver.c.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1341: external/miniupnp/miniupnpc/CMakeFiles/minihttptestserver.dir/all] Error 2

from monero.

SyntheticBird45 avatar SyntheticBird45 commented on July 20, 2024

Compiled successfully from https://github.com/selsta/monero/tree/miniupnpc-2.2.8

from monero.

0xFFFC0000 avatar 0xFFFC0000 commented on July 20, 2024

After adding a small print to src/p2p/CMakeLists.txt :

get_cmake_property(_variableNames VARIABLES)
list (SORT _variableNames)
foreach (_variableName ${_variableNames})
    message(STATUS "${_variableName}=${${_variableName}}")
endforeach()

get_target_property(dirs miniupnpc::miniupnpc INCLUDE_DIRECTORIES)
foreach(dir ${dirs})
  message(STATUS "miniupnpc::miniupnpc INCLUDE_DIRECTORIES='${dir}'")
endforeach()

get_target_property(dirs miniupnpc::miniupnpc INTERFACE_INCLUDE_DIRECTORIES)
foreach(dir ${dirs})
  message(STATUS "miniupnpc::miniupnpc INTERFACE_INCLUDE_DIRECTORIES='${dir}'")
endforeach()

message(WARNING "p2p:")
get_target_property(dirs p2p INCLUDE_DIRECTORIES)
foreach(dir ${dirs})
  message(STATUS "p2p INCLUDE_DIRECTORIES='${dir}'")
endforeach()
get_target_property(dirs p2p INTERFACE_INCLUDE_DIRECTORIES)
foreach(dir ${dirs})
  message(STATUS "p2p INTERFACE_INCLUDE_DIRECTORIES='${dir}'")
endforeach()

you can see this output (even if you add miniupnpc::miniupnpc to p2p as dependency):

-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/rapidjson/include'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/easylogging++'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/src'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/contrib/epee/include'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/supercop/include'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/build-release/generated_include'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/build-release/translations'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='$<BUILD_INTERFACE:/home/0xfffc/developments/monero/external/miniupnp/miniupnpc/include>'
-- miniupnpc::miniupnpc INCLUDE_DIRECTORIES='$<INSTALL_INTERFACE:include/miniupnpc>'
-- miniupnpc::miniupnpc INTERFACE_INCLUDE_DIRECTORIES='$<BUILD_INTERFACE:/home/0xfffc/developments/monero/external/miniupnp/miniupnpc/include>'
-- miniupnpc::miniupnpc INTERFACE_INCLUDE_DIRECTORIES='$<INSTALL_INTERFACE:include/miniupnpc>'
-- miniupnpc::miniupnpc INTERFACE_INCLUDE_DIRECTORIES='$<INSTALL_INTERFACE:include>'
CMake Warning at src/p2p/CMakeLists.txt:71 (message):
  p2p:
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/rapidjson/include'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/easylogging++'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/src'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/contrib/epee/include'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/supercop/include'
-- p2p INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/build-release/generated_include'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/build-release/translations'
-- p2p INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include'
-- p2p INCLUDE_DIRECTORIES='/home/0xfffc/developments/monero/external/db_drivers/liblmdb'
-- p2p INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include/hidapi'
-- p2p INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include'
-- p2p INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include/libusb-1.0'
-- p2p INCLUDE_DIRECTORIES='/opt/monero/build-release/x86_64-pc-linux-gnu/include'
-- p2p INTERFACE_INCLUDE_DIRECTORIES='dirs-NOTFOUND'

It is obvious for some reason the include path from miniupnpc::miniupnpc does not propagate to the p2p target.

And this is the PR causing it: miniupnp/miniupnp#559

from monero.

0xFFFC0000 avatar 0xFFFC0000 commented on July 20, 2024

In case you want to take a look at early PR, this one is a complete fix, other than a few minor issues I expect it to work without issue 0xFFFC0000#23

Once it passed all the tests, I will submit a PR.

from monero.

SyntheticBird45 avatar SyntheticBird45 commented on July 20, 2024

@0xFFFC0000 unable to compile from your branch. Still have error: external/miniupnp/miniupnpc/src/minihttptestserver.c:299:25: error: implicit declaration of function 'usleep'; did you mean 'sleep'? [-Wimplicit-function-declaration]

What I did:

$ git clone https://github.com/0xFFFC0000/monero -b dev/0xfffc/new-miniupnpc && cd monero/
$ git submodule update --init --force
$ make -j 8

from monero.

0xFFFC0000 avatar 0xFFFC0000 commented on July 20, 2024

Yes. That is their error. Not ours. Even if you compile miniupnpc in separate environment with same compiler, you will hit it. ( in your spare time please try it if possible and let me know )

Let me double check though, I will find a workaround.

from monero.

0xFFFC0000 avatar 0xFFFC0000 commented on July 20, 2024

@0xFFFC0000 unable to compile from your branch. Still have error: external/miniupnp/miniupnpc/src/minihttptestserver.c:299:25: error: implicit declaration of function 'usleep'; did you mean 'sleep'? [-Wimplicit-function-declaration]

What I did:

$ git clone https://github.com/0xFFFC0000/monero -b dev/0xfffc/new-miniupnpc && cd monero/
$ git submodule update --init --force
$ make -j 8

Do you use Element? or IRC?

from monero.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.