Trouble with connection mongodb to c project

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
0
down vote

favorite












IDE: Netbeans
Error message



I downloaded mongodb c driver and installed it using instruction from official site, but now when I trying to compile my project I get an error:



gcc -c -g -std=c11 -MMD -MP -MF "build/Debug/GNU-Linux/_ext/a7a8f127/aggregation1.o.d" -o build/Debug/GNU- Linux/_ext/a7a8f127/aggregation1.o ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c
../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c:1:10: fatal error: mongoc.h: No such file or directory
#include <mongoc.h>
^~~~~~~~~~
compilation terminated.



I figured out that problem appeared because of the incorrect path, so next when I wrote



 #include <libmongoc-1.0/mongoc.h> 


instead of just



 #include <mongoc.h> 


but the problem still remained, but now it says that in file "mongoc.h" resolved incorrect path to "bson.h"



There are unresolved includes inside <libmongoc-1.0/mongoc.h>.


For extra info hold Ctrl and move mouse over include directive



and it's true, bson.h is located at "../libbson-1.0/bson.h" in relation with mongoc, and this both libs located at



"usr/include/"



so how can I make correct path for bson? I can't even copy bson.h with all dependencies to "libmongoc" path beacause it says I haven't rights. Maybe I misunderstood something when was trying to follow official documenation, please help me, I would appreciate any help.







share|improve this question
























    up vote
    0
    down vote

    favorite












    IDE: Netbeans
    Error message



    I downloaded mongodb c driver and installed it using instruction from official site, but now when I trying to compile my project I get an error:



    gcc -c -g -std=c11 -MMD -MP -MF "build/Debug/GNU-Linux/_ext/a7a8f127/aggregation1.o.d" -o build/Debug/GNU- Linux/_ext/a7a8f127/aggregation1.o ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c
    ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c:1:10: fatal error: mongoc.h: No such file or directory
    #include <mongoc.h>
    ^~~~~~~~~~
    compilation terminated.



    I figured out that problem appeared because of the incorrect path, so next when I wrote



     #include <libmongoc-1.0/mongoc.h> 


    instead of just



     #include <mongoc.h> 


    but the problem still remained, but now it says that in file "mongoc.h" resolved incorrect path to "bson.h"



    There are unresolved includes inside <libmongoc-1.0/mongoc.h>.


    For extra info hold Ctrl and move mouse over include directive



    and it's true, bson.h is located at "../libbson-1.0/bson.h" in relation with mongoc, and this both libs located at



    "usr/include/"



    so how can I make correct path for bson? I can't even copy bson.h with all dependencies to "libmongoc" path beacause it says I haven't rights. Maybe I misunderstood something when was trying to follow official documenation, please help me, I would appreciate any help.







    share|improve this question






















      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      IDE: Netbeans
      Error message



      I downloaded mongodb c driver and installed it using instruction from official site, but now when I trying to compile my project I get an error:



      gcc -c -g -std=c11 -MMD -MP -MF "build/Debug/GNU-Linux/_ext/a7a8f127/aggregation1.o.d" -o build/Debug/GNU- Linux/_ext/a7a8f127/aggregation1.o ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c
      ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c:1:10: fatal error: mongoc.h: No such file or directory
      #include <mongoc.h>
      ^~~~~~~~~~
      compilation terminated.



      I figured out that problem appeared because of the incorrect path, so next when I wrote



       #include <libmongoc-1.0/mongoc.h> 


      instead of just



       #include <mongoc.h> 


      but the problem still remained, but now it says that in file "mongoc.h" resolved incorrect path to "bson.h"



      There are unresolved includes inside <libmongoc-1.0/mongoc.h>.


      For extra info hold Ctrl and move mouse over include directive



      and it's true, bson.h is located at "../libbson-1.0/bson.h" in relation with mongoc, and this both libs located at



      "usr/include/"



      so how can I make correct path for bson? I can't even copy bson.h with all dependencies to "libmongoc" path beacause it says I haven't rights. Maybe I misunderstood something when was trying to follow official documenation, please help me, I would appreciate any help.







      share|improve this question












      IDE: Netbeans
      Error message



      I downloaded mongodb c driver and installed it using instruction from official site, but now when I trying to compile my project I get an error:



      gcc -c -g -std=c11 -MMD -MP -MF "build/Debug/GNU-Linux/_ext/a7a8f127/aggregation1.o.d" -o build/Debug/GNU- Linux/_ext/a7a8f127/aggregation1.o ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c
      ../../Downloads/mongo-c-driver-1.9.4/examples/aggregation/aggregation1.c:1:10: fatal error: mongoc.h: No such file or directory
      #include <mongoc.h>
      ^~~~~~~~~~
      compilation terminated.



      I figured out that problem appeared because of the incorrect path, so next when I wrote



       #include <libmongoc-1.0/mongoc.h> 


      instead of just



       #include <mongoc.h> 


      but the problem still remained, but now it says that in file "mongoc.h" resolved incorrect path to "bson.h"



      There are unresolved includes inside <libmongoc-1.0/mongoc.h>.


      For extra info hold Ctrl and move mouse over include directive



      and it's true, bson.h is located at "../libbson-1.0/bson.h" in relation with mongoc, and this both libs located at



      "usr/include/"



      so how can I make correct path for bson? I can't even copy bson.h with all dependencies to "libmongoc" path beacause it says I haven't rights. Maybe I misunderstood something when was trying to follow official documenation, please help me, I would appreciate any help.









      share|improve this question











      share|improve this question




      share|improve this question










      asked Apr 23 at 19:37









      Partylover

      32




      32

























          active

          oldest

          votes











          Your Answer







          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "89"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













           

          draft saved


          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1027576%2ftrouble-with-connection-mongodb-to-c-project%23new-answer', 'question_page');

          );

          Post as a guest



































          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1027576%2ftrouble-with-connection-mongodb-to-c-project%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          pylint3 and pip3 broken

          Missing snmpget and snmpwalk

          How to enroll fingerprints to Ubuntu 17.10 with VFS491