Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7822663
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T07:59:09+00:00 2026-06-02T07:59:09+00:00

I have installed Netbeans 7.1.1 connecting to a remote build host (my virtual box).

  • 0

I have installed Netbeans 7.1.1 connecting to a remote build host (my virtual box).
I tried to compile some program I found on certain website.

#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <libxml/tree.h>
#include <libxml/parser.h>
#include <libxml/parserInternals.h>

// Appelée à la rencontre de chaque balise ouvrante
void debut_element(void *user_data, const xmlChar *name, const xmlChar **attrs) {
printf("Début de l'élément : %s\n", name);
}

int main() {
// Initialisation à zéro de tous les membres (NULL pour un pointeur par conversion)
xmlSAXHandler sh = { 0 };

// Affectation des fonctions de rappel
sh.startElement = debut_element;

xmlParserCtxtPtr ctxt;
// Création du contexte
if ((ctxt = xmlCreateFileParserCtxt("catalogue.xml")) == NULL) {
    fprintf(stderr, "Erreur lors de la création du contexte\n");
    return EXIT_FAILURE;
}
// Fonctions de rappel à utiliser
ctxt->sax = &sh;
// Analyse
xmlParseDocument(ctxt);
// Le document est-il bien formé ?
if (ctxt->wellFormed) {
    printf("Document XML bien formé\n");
} else {
    fprintf(stderr, "Document XML mal formé\n");
    xmlFreeParserCtxt(ctxt);
    return EXIT_FAILURE;
}
// Libération de la mémoire
xmlFreeParserCtxt(ctxt);

return EXIT_SUCCESS;
}

However, I got this error message during compilation

Copying project files to /home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/ at saebyuk@redHat
"/usr/bin/gmake" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
gmake[1]: Entering directory `/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat'
"/usr/bin/gmake"  -f nbproject/Makefile-Debug.mk dist/Debug/GNU-Linux-x86/xml_decoder_red_hat
gmake[2]: Entering directory `/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat'
gmake[2]: Warning: File `main.cpp' has modification time 2.1e+04 s in the future
mkdir -p build/Debug/GNU-Linux-x86
rm -f build/Debug/GNU-Linux-x86/main.o.d
g++    -c -g -Wall -I/usr/include/libxml2 -MMD -MP -MF build/Debug/GNU-Linux-x86/main.o.d -o build/Debug/GNU-Linux-x86/main.o main.cpp
mkdir -p dist/Debug/GNU-Linux-x86
g++     -I/usr/include/libxml2 -o dist/Debug/GNU-Linux-x86/xml_decoder_red_hat build/Debug/GNU-Linux-x86/main.o  
build/Debug/GNU-Linux-x86/main.o: In function `main':
/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat/main.cpp:35: undefined reference to `xmlCreateFileParserCtxt'
/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat/main.cpp:40: undefined reference to `xmlParseDocument'
/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat/main.cpp:46: undefined reference to `xmlFreeParserCtxt'
collect2: ld returned 1 exit status
gmake[2]: *** [dist/Debug/GNU-Linux-x86/xml_decoder_red_hat] Error 1
gmake[2]: Leaving directory `/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat'
gmake[1]: *** [.build-conf] Error 2
gmake[1]: Leaving directory `/home/saebyuk/.netbeans/remote/redHat/saebyuk-pc-Windows-x86/C/Users/saebyuk/Documents/NetBeansProjects/xml_decoder_Red_hat'
gmake: *** [.build-impl] Error 2

I know this has been asked thousands of times here but I couldn’t find the correct answer.
Appreciate if anyone of you could guide me as I am new in this.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T07:59:10+00:00Added an answer on June 2, 2026 at 7:59 am

    I don’t know how to configure Netbeans; but your code compiles without trouble if you execute this command by hand:

    gcc -o xmltest xmltest.c -I /usr/include/libxml2 -lxml2
    

    If you don’t yet have a Makefile, this is a good start:

    LDFLAGS := -I /usr/include/libxml2 -lxml2
    

    But, if Netbeans forces you to use a different build system, you’ll have to figure out another way to set the linker options appropriately.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How can I run a program with Notepad++ if I have Netbeans installed? I
i have installed the netbeans version 6.8 with glassfish version 3 on a redhat
I have installed the latest version of netbeans and its working.. I have opened
i have installed the latest netbeans 6.9 rc2 for all languages, but i only
Java, ANTLR and Netbeans newbie here. I have installed a jdk and netbeans. I
I just installed NetBeans, and want to try it out. Some context tips (popup
I have NetBeans 7.01 and installed the Git plugin from the plugins panel After
I'm a java newbie, want to test out some hibernate goodies! I have netbeans
i have installed the cygwin package for my netbeans IDE. I can use that
I installed Netbeans then I tried to checkout my projects inside Netbeans. During the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.