GithubHelp home page GithubHelp logo

Ubuntu/Linux Port? about lpvpn HOT 6 OPEN

gyf304 avatar gyf304 commented on August 23, 2024 1
Ubuntu/Linux Port?

from lpvpn.

Comments (6)

gyf304 avatar gyf304 commented on August 23, 2024

It uses the Discord Game API for connectivity, which uses the Discord Servers.
See https://discord.com/developers/docs/game-sdk/lobbies

Regarding support on Linux. LPVPN is written with portability in mind, but the only thing we currently support is Windows (since the majority of players use Windows).

To support Linux, one would write a TUN implementation of this interface https://github.com/gyf304/lpvpn/blob/main/src/adapter.h

I may do this at some point in the future if I have weekend cycles available, but not at the current moment.
Feel free to try implementing it and report back!

from lpvpn.

 avatar commented on August 23, 2024

I wonder if it could be extended to Android as well.
There are some games/emulators you could use it with.
Best examples that comes to mind are PPSSPP and Flycast.

from lpvpn.

Laezor avatar Laezor commented on August 23, 2024

Well I am able to run it with wine. But when I click either host or join, I get this error.
image

from lpvpn.

arrowgent avatar arrowgent commented on August 23, 2024

would be awesome to have on linux x86_64 and armhf aarm64

from lpvpn.

arrowgent avatar arrowgent commented on August 23, 2024

current cmake report in linux:

git clone https://github.com/gyf304/lpvpn
Cloning into 'lpvpn'...
remote: Enumerating objects: 264, done.
remote: Counting objects: 100% (264/264), done.
remote: Compressing objects: 100% (183/183), done.
remote: Total 264 (delta 117), reused 158 (delta 45), pack-reused 0
Receiving objects: 100% (264/264), 221.54 KiB | 5.83 MiB/s, done.
Resolving deltas: 100% (117/117), done.
linux ~/Downloads/build/lpvpn $ cd lpvpn/
linux ~/Downloads/build/lpvpn/lpvpn $ mkdir build
linux ~/Downloads/build/lpvpn/lpvpn $ cd build
linux ~/Downloads/build/lpvpn/lpvpn/build $ cmake ..
-- The C compiler identification is GNU 9.3.0
-- The CXX compiler identification is GNU 9.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Platform: 
-- Generator Platform: 
-- POPULATE /home/catbox/Downloads/build/lpvpn/lpvpn/build/_deps/discordgamesdk-src
-- DiscordGameSDK_SDKROOT at /home/catbox/Downloads/build/lpvpn/lpvpn/build/_deps/discordgamesdk-src
-- Setting build type to 'Debug' as none was specified.
-- cotire 1.8.0 loaded.
-- Found X11: /usr/include   
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1") 
-- Found GTK3: /usr/include/gtk-3.0;/usr/include/at-spi2-atk/2.0;/usr/include/at-spi-2.0;/usr/include/dbus-1.0;/usr/lib/x86_64-linux-gnu/dbus-1.0/include;/usr/include/gtk-3.0;/usr/include/gio-unix-2.0/;/usr/include/cairo;/usr/include/pango-1.0;/usr/include/harfbuzz;/usr/include/pango-1.0;/usr/include/fribidi;/usr/include/atk-1.0;/usr/include/cairo;/usr/include/pixman-1;/usr/include/uuid;/usr/include/freetype2;/usr/include/libpng16;/usr/include/gdk-pixbuf-2.0;/usr/include/libpng16;/usr/include/glib-2.0;/usr/lib/x86_64-linux-gnu/glib-2.0/include  
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11") 
-- Found EXPAT: /usr/lib/x86_64-linux-gnu/libexpat.so (found version "2.2.10") 
-- Found JPEG: /usr/lib/x86_64-linux-gnu/libjpeg.so (found version "80") 
-- Found PNG: /usr/lib/x86_64-linux-gnu/libpng.so (found version "1.6.37") 
-- Found TIFF: /usr/lib/x86_64-linux-gnu/libtiff.so (found version "4.3.0")  
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE  
-- Could NOT find LIBSECRET (missing: LIBSECRET_INCLUDE_DIRS LIBSECRET_LIBRARIES) 
CMake Warning at build/_deps/wxwidgets-src/build/cmake/init.cmake:317 (message):
  libsecret not found, wxSecretStore won't be available
Call Stack (most recent call first):
  build/_deps/wxwidgets-src/build/cmake/main.cmake:16 (include)
  build/_deps/wxwidgets-src/CMakeLists.txt:69 (include)


-- Found Iconv: /usr/lib/x86_64-linux-gnu/libc.so
-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so   
-- Could NOT find LIBSOUP (missing: LIBSOUP_INCLUDE_DIRS LIBSOUP_LIBRARIES) (found version "")
-- Could NOT find WEBKIT2 (missing: WEBKIT2_LIBRARY WEBKIT2_INCLUDE_DIR) 
-- Could NOT find WEBKIT (missing: WEBKIT_LIBRARY WEBKIT_INCLUDE_DIR) (Required is at least version "3.0")
CMake Warning at build/_deps/wxwidgets-src/build/cmake/init.cmake:415 (message):
  webkit not found or enabled, wxWebview won't be available
Call Stack (most recent call first):
  build/_deps/wxwidgets-src/build/cmake/main.cmake:16 (include)
  build/_deps/wxwidgets-src/CMakeLists.txt:69 (include)


-- Could NOT find GSTREAMER (missing: GSTREAMER_VERSION GSTREAMER_INCLUDE_DIRS GSTREAMER_LIBRARIES GSTREAMER_BASE_INCLUDE_DIRS GSTREAMER_BASE_LIBRARIES GSTREAMER_VIDEO_INCLUDE_DIRS GSTREAMER_VIDEO_LIBRARIES) (Required is at least version "1.0")
-- Could NOT find GSTREAMER (missing: GSTREAMER_VERSION GSTREAMER_INCLUDE_DIRS GSTREAMER_LIBRARIES GSTREAMER_BASE_INCLUDE_DIRS GSTREAMER_BASE_LIBRARIES GSTREAMER_INTERFACES_INCLUDE_DIRS GSTREAMER_INTERFACES_LIBRARIES) (Required is at least version "0.10")
CMake Warning at build/_deps/wxwidgets-src/build/cmake/init.cmake:453 (message):
  GStreamer not found, wxMediaCtrl won't be available
Call Stack (most recent call first):
  build/_deps/wxwidgets-src/build/cmake/main.cmake:16 (include)
  build/_deps/wxwidgets-src/CMakeLists.txt:69 (include)


-- Found SDL2: /usr/lib/x86_64-linux-gnu/libSDL2main.a;/usr/lib/x86_64-linux-gnu/libSDL2.so;-lpthread  
-- Found XTEST: /usr/lib/x86_64-linux-gnu/libXtst.so  
-- Could NOT find MSPACK (missing: MSPACK_LIBRARY MSPACK_INCLUDE_DIR) 
-- libmspack not found
-- CXX target wxscintilla cotired without unity build.
-- C CXX target wxmono cotired without unity build.
-- Looking for 4 include files stdlib.h, ..., float.h
-- Looking for 4 include files stdlib.h, ..., float.h - found
-- Looking for va_copy
-- Looking for va_copy - found
-- Performing Test HAVE_VARIADIC_MACROS
-- Performing Test HAVE_VARIADIC_MACROS - Success
-- Performing Test HAVE_STD_STRING_COMPARE
-- Performing Test HAVE_STD_STRING_COMPARE - Success
-- Performing Test HAVE_STD_WSTRING
-- Performing Test HAVE_STD_WSTRING - Success
-- Performing Test HAVE_HASH_MAP
-- Performing Test HAVE_HASH_MAP - Failed
-- Performing Test HAVE_EXT_HASH_MAP
-- Performing Test HAVE_EXT_HASH_MAP - Success
-- Performing Test HAVE_STD_UNORDERED_MAP
-- Performing Test HAVE_STD_UNORDERED_MAP - Success
-- Performing Test HAVE_TR1_UNORDERED_MAP
-- Performing Test HAVE_TR1_UNORDERED_MAP - Success
-- Performing Test HAVE_GCC_ATOMIC_BUILTINS
-- Performing Test HAVE_GCC_ATOMIC_BUILTINS - Success
-- Looking for sigaction
-- Looking for sigaction - found
-- Performing Test wxTYPE_SA_HANDLER_IS_INT
-- Performing Test wxTYPE_SA_HANDLER_IS_INT - Success
-- Performing Test wxHAVE_BACKTRACE
-- Performing Test wxHAVE_BACKTRACE - Success
-- Performing Test HAVE_CXA_DEMANGLE
-- Performing Test HAVE_CXA_DEMANGLE - Success
-- Looking for mkstemp
-- Looking for mkstemp - found
-- Looking for mktemp
-- Looking for mktemp - found
-- Performing Test HAVE_STATFS
-- Performing Test HAVE_STATFS - Success
-- Performing Test HAVE_STATFS_DECL
-- Performing Test HAVE_STATFS_DECL - Success
-- Looking for fcntl
-- Looking for fcntl - found
-- Looking for flock
-- Looking for flock - found
-- Looking for setenv
-- Looking for setenv - found
-- Looking for putenv
-- Looking for putenv - found
-- Looking for unsetenv
-- Looking for unsetenv - found
-- Looking for nanosleep
-- Looking for nanosleep - found
-- Looking for uname
-- Looking for uname - found
-- Looking for gethostname
-- Looking for gethostname - found
-- Looking for strtok_r
-- Looking for strtok_r - found
-- Looking for fdopen
-- Looking for fdopen - found
-- Looking for sysconf
-- Looking for sysconf - found
-- Looking for getpwuid_r
-- Looking for getpwuid_r - found
-- Looking for getgrgid_r
-- Looking for getgrgid_r - found
-- Looking for sys/soundcard.h
-- Looking for sys/soundcard.h - found
-- Performing Test WX_SOCKLEN_T_IS_SOCKLEN_T
-- Performing Test WX_SOCKLEN_T_IS_SOCKLEN_T - Success
-- Performing Test SOCKOPTLEN_T_IS_SOCKLEN_T
-- Performing Test SOCKOPTLEN_T_IS_SOCKLEN_T - Success
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for gethostbyname_r
-- Looking for gethostbyname_r - found
-- Checking prototype gethostbyname_r for HAVE_FUNC_GETHOSTBYNAME_R_3
-- Checking prototype gethostbyname_r for HAVE_FUNC_GETHOSTBYNAME_R_3 - False
-- Checking prototype gethostbyname_r for HAVE_FUNC_GETHOSTBYNAME_R_5
-- Checking prototype gethostbyname_r for HAVE_FUNC_GETHOSTBYNAME_R_5 - False
-- Checking prototype gethostbyname_r for HAVE_FUNC_GETHOSTBYNAME_R_6
-- Checking prototype gethostbyname_r for HAVE_FUNC_GETHOSTBYNAME_R_6 - True
-- Looking for getservbyname
-- Looking for getservbyname - found
-- Looking for inet_aton
-- Looking for inet_aton - found
-- Looking for inet_addr
-- Looking for inet_addr - found
-- Performing Test wxHAVE_PTHREAD_CLEANUP
-- Performing Test wxHAVE_PTHREAD_CLEANUP - Success
-- Performing Test HAVE_PTHREAD_MUTEXATTR_T
-- Performing Test HAVE_PTHREAD_MUTEXATTR_T - Success
-- Performing Test HAVE_PTHREAD_MUTEXATTR_SETTYPE_DECL
-- Performing Test HAVE_PTHREAD_MUTEXATTR_SETTYPE_DECL - Success
-- Performing Test HAVE___THREAD_KEYWORD
-- Performing Test HAVE___THREAD_KEYWORD - Success
-- Performing Test HAVE_ABI_FORCEDUNWIND
-- Performing Test HAVE_ABI_FORCEDUNWIND - Success
-- Looking for localtime_r
-- Looking for localtime_r - found
-- Looking for gmtime_r
-- Looking for gmtime_r - found
-- Performing Test wxSIZE_T_IS_NOT_UINT
-- Performing Test wxSIZE_T_IS_NOT_UINT - Success
-- Performing Test wxSIZE_T_IS_NOT_ULONG
-- Performing Test wxSIZE_T_IS_NOT_ULONG - Failed
-- Performing Test wxWCHAR_T_IS_REAL_TYPE
-- Performing Test wxWCHAR_T_IS_REAL_TYPE - Success
-- Performing Test HAVE_PW_GECOS
-- Performing Test HAVE_PW_GECOS - Success
-- Looking for ftime
-- Looking for ftime - not found
-- Looking for wcsftime
-- Looking for wcsftime - found
-- Looking for wprintf
-- Looking for wprintf - found
-- Looking for putws
-- Looking for putws - not found
-- Looking for fputws
-- Looking for fputws - found
-- Looking for vswprintf
-- Looking for vswprintf - found
-- Looking for vswscanf
-- Looking for vswscanf - found
-- Looking for wcsdup
-- Looking for wcsdup - found
-- Looking for wcsnlen
-- Looking for wcsnlen - found
-- Looking for wcscasecmp
-- Looking for wcscasecmp - found
-- Looking for wcsncasecmp
-- Looking for wcsncasecmp - found
-- Looking for wcsrctombs
-- Looking for wcsrctombs - not found
-- Looking for wcstoull
-- Looking for wcstoull - found
-- Looking for wcslen
-- Looking for wcslen - found
-- Looking for fsync
-- Looking for fsync - found
-- Looking for snprintf
-- Looking for snprintf - found
-- Looking for vsnprintf
-- Looking for vsnprintf - found
-- Looking for strnlen
-- Looking for strnlen - found
-- Looking for strtoull
-- Looking for strtoull - found
-- Looking for setpriority
-- Looking for setpriority - found
-- Looking for round
-- Looking for round - not found
-- Looking for C++ include tr1/type_traits
-- Looking for C++ include tr1/type_traits - found
-- Looking for C++ include type_traits
-- Looking for C++ include type_traits - found
-- Looking for fcntl.h
-- Looking for fcntl.h - found
-- Looking for langinfo.h
-- Looking for langinfo.h - found
-- Looking for sched.h
-- Looking for sched.h - found
-- Looking for unistd.h
-- Looking for unistd.h - found
-- Looking for w32api.h
-- Looking for w32api.h - not found
-- Looking for wchar.h
-- Looking for wchar.h - found
-- Looking for wcstr.h
-- Looking for wcstr.h - not found
-- Performing Test wxTEST_TZ_timezone
-- Performing Test wxTEST_TZ_timezone - Success
-- Performing Test WX_GMTOFF_IN_TM
-- Performing Test WX_GMTOFF_IN_TM - Success
-- Looking for dlopen
-- Looking for dlopen - found
-- Looking for dladdr
-- Looking for dladdr - not found
-- Looking for gettimeofday
-- Looking for gettimeofday - found
-- Looking for sys/epoll.h
-- Looking for sys/epoll.h - found
-- Looking for sys/select.h
-- Looking for sys/select.h - found
-- Looking for sys/inotify.h
-- Looking for sys/inotify.h - found
-- Looking for xlocale.h
-- Looking for xlocale.h - not found
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of locale_t
-- Check size of locale_t - done
-- Check size of pid_t
-- Check size of pid_t - done
-- Check size of size_t
-- Check size of size_t - done
-- Check size of wchar_t
-- Check size of wchar_t - done
-- Check size of int
-- Check size of int - done
-- Check size of long
-- Check size of long - done
-- Check size of short
-- Check size of short - done
-- Check size of gid_t
-- Check size of gid_t - done
-- Check size of uid_t
-- Check size of uid_t - done
-- Check size of mode_t
-- Check size of mode_t - done
-- Check size of off_t
-- Check size of off_t - done
-- Check size of long long
-- Check size of long long - done
-- Check size of ssize_t
-- Check size of ssize_t - done
-- Which libraries should wxWidgets use?
    wxUSE_STL:        OFF      (use C++ STL classes)
    wxUSE_REGEX:      builtin  (enable support for wxRegEx class)
    wxUSE_ZLIB:       sys      (use zlib for LZW compression)
    wxUSE_EXPAT:      sys      (use expat for XML parsing)
    wxUSE_LIBJPEG:    sys      (use libjpeg (JPEG file format))
    wxUSE_LIBPNG:     sys      (use libpng (PNG image format))
    wxUSE_LIBTIFF:    sys      (use libtiff (TIFF file format))
    wxUSE_LIBLZMA:    OFF      (use liblzma for LZMA compression)
    wxUSE_LIBSDL:     ON       (use SDL for audio on Unix)
    wxUSE_LIBMSPACK:  OFF      (use libmspack (CHM help files loading))

-- Configured wxWidgets 3.1.4 for Linux-5.4.0-97-generic
    Min OS Version required at runtime:                Linux x86_64
    Which GUI toolkit should wxWidgets use?            gtk3 3.22.30
    Should wxWidgets be compiled into single library?  ON
    Should wxWidgets be linked as a shared library?    OFF
    Should wxWidgets support Unicode?                  ON
    What wxWidgets compatibility level should be used? 3.0
-- Configuring done
-- Generating done
-- Build files have been written to: /home/catbox/Downloads/build/lpvpn/lpvpn/build
linux ~/Downloads/build/lpvpn/lpvpn/build $ make
[  0%] Building C object CMakeFiles/MemoryModule.dir/_deps/memorymodule-src/MemoryModule.c.o
/home/catbox/Downloads/build/lpvpn/lpvpn/build/_deps/memorymodule-src/MemoryModule.c:38:10: fatal error: windows.h: No such file or directory
   38 | #include <windows.h>
      |          ^~~~~~~~~~~
compilation terminated.
make[2]: *** [CMakeFiles/MemoryModule.dir/build.make:76: CMakeFiles/MemoryModule.dir/_deps/memorymodule-src/MemoryModule.c.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:413: CMakeFiles/MemoryModule.dir/all] Error 2
make: *** [Makefile:136: all] Error 2

so this suggests the C++ code is mostly cross platform.
some work and this will build, mainly removing static libaries for windows, replace them with cmake checks to determine platform.
im not a programmer, so i cant help develop this.

#13

git clone https://github.com/gyf304/lpvpn/
cd lpvpn
mkdir build
cd build
cmake ..
make

not sure if make is correct here. make is usually good for C programming where g++ is used in C++

from lpvpn.

 avatar commented on August 23, 2024

Did someone found a way to to run it on Linux?

from lpvpn.

Related Issues (12)

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.