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

This plugin does not compile on Ubuntu 22.04 with DS 7.0 #13

Open
neilyoung opened this issue Sep 15, 2024 · 3 comments
Open

This plugin does not compile on Ubuntu 22.04 with DS 7.0 #13

neilyoung opened this issue Sep 15, 2024 · 3 comments

Comments

@neilyoung
Copy link

As subject says.

g++ -c -o gstnvinfer.o -fPIC -std=c++11 -DDS_VERSION=\"7.0\" -I /usr/local/cuda-12.2/include -I /opt/nvidia/deepstream/deepstream-7.0/sources/includes -I /opt/nvidia/deepstream/deepstream-7.0/sources/gst-plugins/gst-nvdspreprocess/include -I /opt/nvidia/deepstream/deepstream-7.0/sources/libs/nvdsinfer -DNDEBUG -pthread -I/usr/include/opencv4 -I/usr/include/gstreamer-1.0 -I/usr/include/orc-0.4 -I/usr/include/gstreamer-1.0 -I/usr/include/x86_64-linux-gnu -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include gstnvinfer.cpp
In file included from /usr/include/glib-2.0/glib/gthread.h:32,
                 from /usr/include/glib-2.0/glib/gasyncqueue.h:32,
                 from /usr/include/glib-2.0/glib.h:32,
                 from /usr/include/gstreamer-1.0/gst/gst.h:27,
                 from /opt/nvidia/deepstream/deepstream-7.0/sources/includes/gst-nvevent.h:36,
                 from gstnvinfer.cpp:25:
gstnvinfer.cpp: In function ‘GType gst_nvinfer_process_mode_get_type()’:
/usr/include/glib-2.0/glib/gatomic.h:113:19: error: argument 2 of ‘__atomic_load’ must not be a pointer to a ‘volatile’ type
  113 |     __atomic_load (gapg_temp_atomic, &gapg_temp_newval, __ATOMIC_SEQ_CST); \
      |     ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/glib-2.0/glib/gthread.h:260:7: note: in expansion of macro ‘g_atomic_pointer_get’
  260 |     (!g_atomic_pointer_get (location) &&                             \
      |       ^~~~~~~~~~~~~~~~~~~~
gstnvinfer.cpp:169:7: note: in expansion of macro ‘g_once_init_enter’
  169 |   if (g_once_init_enter (&process_mode_type)) {
      |       ^~~~~~~~~~~~~~~~~
In file included from gstnvinfer.cpp:31:
gstnvinfer.cpp: In function ‘GstFlowReturn gst_nvinfer_process_objects(GstNvInfer*, GstBuffer*, NvBufSurface*)’:
gstnvinfer_meta_utils.h:23:64: warning: ISO C++ forbids converting a string constant to ‘gchar*’ {aka ‘char*’} [-Wwrite-strings]
   23 | #define NVDS_USER_OBJECT_META_EXAMPLE (nvds_get_user_meta_type("NVIDIA.NVINFER.USER_META"))
      |                                                                ^~~~~~~~~~~~~~~~~~~~~~~~~~
gstnvinfer_meta_utils.h:23:64: note: in definition of macro ‘NVDS_USER_OBJECT_META_EXAMPLE’
   23 | #define NVDS_USER_OBJECT_META_EXAMPLE (nvds_get_user_meta_type("NVIDIA.NVINFER.USER_META"))
      |                                                                ^~~~~~~~~~~~~~~~~~~~~~~~~~
gstnvinfer.cpp: In function ‘std::tuple<cv::Mat, cv::Mat> get_images(GstNvInfer*, NvDsObjectMeta*, float, float, float (*)[2])’:
gstnvinfer.cpp:1542:1: warning: control reaches end of non-void function [-Wreturn-type]
 1542 | }
      | ^
gstnvinfer.cpp: In function ‘cv::Mat align_preprocess(NvBufSurface*, cv::Mat&, int, int, cv::Mat&)’:
gstnvinfer.cpp:1591:1: warning: control reaches end of non-void function [-Wreturn-type]
 1591 | }
      | ^
make: *** [Makefile:54: gstnvinfer.o] Error 1
@neilyoung
Copy link
Author

PS: The original gst-nvinfer plugin compiles fine.

@vieduy
Copy link

vieduy commented Sep 17, 2024

I have this problem too. Anyone have the solution for this error? Thanks
Edit: Solved by install gcc-9 g++-9

@Vishwa0703
Copy link

@vieduy are you able to do alignment using the yolov8n-face

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

No branches or pull requests

3 participants