Ad Widget

Collapse

FreeBSD 6.2 configure failes 1.4.1

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Logicwrath
    Junior Member
    • Feb 2007
    • 27

    #1

    FreeBSD 6.2 configure failes 1.4.1

    With:

    ./configure --enable-agent --enable-server --with-mysql --with-net-snmp --with-libcurl=/usr/local

    I am getting:

    checking for curl-config... /usr/local
    configure: error: Not found Curl library

    I have also tried /usr/local/bin and /usr/local/bin/curl-config

    Also:

    configure: WARNING: sys/mount.h: present but cannot be compiled
    configure: WARNING: sys/mount.h: check for missing prerequisite headers?
    configure: WARNING: sys/mount.h: see the Autoconf documentation
    configure: WARNING: sys/mount.h: section "Present But Cannot Be Compiled"
    configure: WARNING: sys/mount.h: proceeding with the preprocessor's result
    configure: WARNING: sys/mount.h: in the future, the compiler will take precedence
  • Alexei
    Founder, CEO
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Sep 2004
    • 5654

    #2
    Use this option --with-libcurl=/usr/local/bin. It must point to location of the curl_config, see ./configure --help.
    Alexei Vladishev
    Creator of Zabbix, Product manager
    New York | Tokyo | Riga
    My Twitter

    Comment

    • Logicwrath
      Junior Member
      • Feb 2007
      • 27

      #3
      Thanks for you interest.

      "I have also tried /usr/local/bin and /usr/local/bin/curl-config"

      I tried again with :

      ./configure --enable-agent --enable-server --with-mysql --with-net-snmp --with-libcurl=/usr/local/bin


      checking for curl-config... /usr/local/bin
      configure: error: Not found Curl library

      [root@vismon /usr/local/bin]# ls curl*
      curl curl-config

      Comment

      • Logicwrath
        Junior Member
        • Feb 2007
        • 27

        #4
        I did get this to work finally. I added some symlinks but I do not think that is what did it.

        The final solution did end up using /usr/local/bin/curl-config. Fifth times the charm? I swear I tried this before and it didnt work.

        Comment

        • aalexanderr
          Junior Member
          • Jul 2007
          • 26

          #5
          Originally posted by Logicwrath
          Thanks for you interest.
          "I have also tried /usr/local/bin and /usr/local/bin/curl-config"
          I tried again with :
          ./configure --enable-agent --enable-server --with-mysql --with-net-snmp --with-libcurl=/usr/local/bin

          checking for curl-config... /usr/local/bin
          configure: error: Not found Curl library
          [root@vismon /usr/local/bin]# ls curl*
          curl curl-config
          Yeap... this is a bad thing ..

          Try this:
          find / -name "libcurl*"
          if you libraries in /usr/local/lib/libcurl.* when just do:
          cp /usr/local/lib/libcurl /usr/lib

          run: ./configure --enable-agent --enable-server --with-mysql --with-net-snmp --with-libcurl=/usr/local/bin/curl-config

          Comment

          • Alexei
            Founder, CEO
            Zabbix Certified Trainer
            Zabbix Certified SpecialistZabbix Certified Professional
            • Sep 2004
            • 5654

            #6
            curl_config must be in sync with your libraries. If curl_config returns wrong location of its libraries, ./configure won't work.
            Alexei Vladishev
            Creator of Zabbix, Product manager
            New York | Tokyo | Riga
            My Twitter

            Comment

            • aalexanderr
              Junior Member
              • Jul 2007
              • 26

              #7
              Originally posted by Alexei
              curl_config must be in sync with your libraries. If curl_config returns wrong location of its libraries, ./configure won't work.
              I install curl in /usr/local (by default):
              #/usr/local/bin/curl-config --prefix
              /usr/local
              #/usr/local/bin/curl-config --libs
              /usr/local/lib

              but when i run ./configure --enable-agent --enable-server --with-mysql --with-net-snmp --with-libcurl=/usr/local
              or --with-libcurl=/usr/local/bin/curl-config configure return error... libcurl not found.
              after cp /usr/local/libs/curl* to /usr/libs all works fine...

              Comment

              • Alexei
                Founder, CEO
                Zabbix Certified Trainer
                Zabbix Certified SpecialistZabbix Certified Professional
                • Sep 2004
                • 5654

                #8
                That's exactly what I'm talking about!

                #/usr/local/bin/curl-config --libs
                /usr/local/lib

                Your curl-config incorrectly states that the libraries are installed in /usr/local/lib while they are actually in a different location.
                Alexei Vladishev
                Creator of Zabbix, Product manager
                New York | Tokyo | Riga
                My Twitter

                Comment

                • aalexanderr
                  Junior Member
                  • Jul 2007
                  • 26

                  #9
                  Originally posted by Alexei
                  That's exactly what I'm talking about!

                  #/usr/local/bin/curl-config --libs
                  /usr/local/lib

                  Your curl-config incorrectly states that the libraries are installed in /usr/local/lib while they are actually in a different location.
                  NO !!!! Libraries instaled in /usr/local/lib !!!!!!!!
                  #ls /usr/local/lib/libcurl*
                  libcurl.a
                  libcurl.la
                  libcurl.so
                  libcurl.so.4

                  and #/usr/local/bin/curl-config --libs tell that :
                  /usr/local/lib
                  .............

                  and when i copy files from /usr/local/lib/libcurl* to /usr/lib/ zabbix correctly find curl libraries..

                  Comment

                  • Alexei
                    Founder, CEO
                    Zabbix Certified Trainer
                    Zabbix Certified SpecialistZabbix Certified Professional
                    • Sep 2004
                    • 5654

                    #10
                    Your curl-config is broken! It should generate the following output:

                    zabbix@ubuntu3:~/1.4.2$ curl-config --libs
                    -L/usr/lib -lcurl -L/usr/lib -lgssapi_krb5 -lkrb5 -lk5crypto -lkrb5support -lcom_err -lresolv -lidn -lssl -lcrypto -ldl -lssl -lcrypto -lz

                    Pay attention to -L and -l parameters.
                    Alexei Vladishev
                    Creator of Zabbix, Product manager
                    New York | Tokyo | Riga
                    My Twitter

                    Comment

                    • aalexanderr
                      Junior Member
                      • Jul 2007
                      • 26

                      #11
                      Originally posted by Alexei
                      Your curl-config is broken! It should generate the following output:

                      zabbix@ubuntu3:~/1.4.2$ curl-config --libs
                      -L/usr/lib -lcurl -L/usr/lib -lgssapi_krb5 -lkrb5 -lk5crypto -lkrb5support -lcom_err -lresolv -lidn -lssl -lcrypto -ldl -lssl -lcrypto -lz

                      Pay attention to -L and -l parameters.
                      No my curl-config not broken.. i just copy part of the string what give me my curl-config --libs.
                      ./curl-config --libs:
                      -L/usr/local/lib -lcurl -lssl -lcrypto -lz

                      This is normal string.. My curl is't broken.

                      Comment

                      • mrdarcy
                        Junior Member
                        Zabbix Certified Specialist
                        • Oct 2006
                        • 5

                        #12
                        Originally posted by Alexei
                        Your curl-config is broken! It should generate the following output:

                        zabbix@ubuntu3:~/1.4.2$ curl-config --libs
                        -L/usr/lib -lcurl -L/usr/lib -lgssapi_krb5 -lkrb5 -lk5crypto -lkrb5support -lcom_err -lresolv -lidn -lssl -lcrypto -ldl -lssl -lcrypto -lz

                        Pay attention to -L and -l parameters.
                        Under FreeBSD, with curl & net-snmp installed from the ports or packages, the curl & net-snmp libs live in /usr/local/lib/

                        Alexei, maybe you manually installed the curl libs on your FreeBSD test environment into /usr/lib ?
                        Afaik, under FreeBSD all user added software is supposed to go here: /usr/local/

                        e.g. /usr/local/bin/curl-config or /usr/local/lib/libcurl.so

                        Since curl is not part of the default FreeBSD installation, it's libs could never live /usr/lib unless manually installed or copied there.


                        btw, I use the LDFLAGS env var for zabbix 1.4.1 under freebsd 6.2, works fine for me:

                        ./configure --enable-agent --enable-server --with-mysql --with-net-snmp --with-libcurl LDFLAGS="-L/usr/local/lib"

                        Comment

                        • jacob.hamacher
                          Junior Member
                          • Sep 2007
                          • 5

                          #13
                          FreeBSD 6.2: configure curl fails with Zabbix 1.4.2

                          I would also like to add to this thread. There is a problem with the configure script for FreeBSD. Zabbix assumes libcurl is installed in /usr/lib, but that is not the FreeBSD way. FreeBSD always install ports in /usr/local/lib. And I believe most FreeBSD admins prefer to install Zabbix from the ports system.

                          See my output below. Is there something the Zabbix developers can do, or is this something that the FreeBSD port maintainer of Zabbix should fix?

                          Code:
                          $ uname -a
                          FreeBSD <hostname_removed> 6.2-RELEASE-p4 FreeBSD 6.2-RELEASE-p4 #0: Thu Apr 26 17:40:53 UTC 2007     [email protected]:/usr/obj/usr/src/sys/GENERIC  i386
                          
                          $ portversion -v zabbix
                          zabbix-1.4.2,1              =  up-to-date with port
                          
                          $ which curl-config
                          /usr/local/bin/curl-config
                          
                          $ curl-config --libs
                          -L/usr/local/lib -lcurl -rpath=/usr/lib:/usr/local/lib -lssl -lcrypto -lz
                          But I really like Zabbix! Easy to setup, easy to get started, yet powerful and possible to adapt to many uses. Thank you for a good product!


                          /Jacob Hamacher

                          Comment

                          • NOB
                            Senior Member
                            Zabbix Certified Specialist
                            • Mar 2007
                            • 469

                            #14
                            Hi,

                            I use - like one of the posters before - the LDFLAGS setting prior
                            to running "./configure".

                            My configure command looks like - of course all in one line:

                            LDFLAGS="-L /usr/local/lib -lssl" ./configure --enable-server --enable-agent --with-pgsql --with-net-snmp --with-libcurl=/usr/local/bin/curl-config --with-jabber

                            Net-SNMP from packages (via Internet, not on CD),
                            Postgresql from ports
                            Curl from ports
                            iksemel from ports
                            apache from packages (via Internet, not on CD)
                            PHP from ports but reconfigured later (Ports was not sufficient - no XML-support)

                            I think that -lssl was necessary for libcurl.

                            HTH,

                            Norbert.

                            Comment

                            Working...