# Apache compilation problems



## wiz (Jul 4, 2004)

take a look at the errors i get..  undef symbols.. how? ...do the multiple definitions of symbols affect this? ... anyway to fix it? ...work-arounds..?

```
/Users/wiz/Desktop/httpd-2.0.50/srclib/apr/libtool --silent --mode=link gcc  -g -O2    -DDARWIN -DSIGPROCMASK_SETS_THREAD_MASK -no-cpp-precomp -DAP_HAVE_DESIGNATED_INITIALIZER -I/sw/include -I/usr/include -I/usr/local/include  -I/Users/wiz/Desktop/httpd-2.0.50/srclib/apr/include -I/Users/wiz/Desktop/httpd-2.0.50/srclib/apr-util/include -I/Users/wiz/Desktop/httpd-2.0.50/srclib/apr-util/xml/expat/lib -I. -I/Users/wiz/Desktop/httpd-2.0.50/os/unix -I/Users/wiz/Desktop/httpd-2.0.50/server/mpm/prefork -I/Users/wiz/Desktop/httpd-2.0.50/modules/http -I/Users/wiz/Desktop/httpd-2.0.50/modules/filters -I/Users/wiz/Desktop/httpd-2.0.50/modules/proxy -I/Users/wiz/Desktop/httpd-2.0.50/include -I/Users/wiz/Desktop/httpd-2.0.50/modules/generators -I/sw/include/openssl -I/sw/include -I/Users/wiz/Desktop/httpd-2.0.50/modules/dav/main -export-dynamic -L/Users/wiz/Desktop/httpd-2.0.50/srclib/apr-util/xml/expat/lib  -L/sw/lib -L/usr/lib -L/usr/local/lib -o httpd  modules.lo  modules/aaa/mod_access.la modules/aaa/mod_auth.la modules/aaa/mod_auth_dbm.la modules/aaa/mod_auth_digest.la modules/cache/mod_file_cache.la modules/experimental/mod_charset_lite.la modules/experimental/mod_cache.la modules/experimental/mod_disk_cache.la modules/experimental/mod_mem_cache.la modules/experimental/mod_case_filter.la modules/experimental/mod_case_filter_in.la modules/filters/mod_ext_filter.la modules/filters/mod_include.la modules/filters/mod_deflate.la modules/loggers/mod_log_config.la modules/loggers/mod_logio.la modules/metadata/mod_env.la modules/metadata/mod_mime_magic.la modules/metadata/mod_cern_meta.la modules/metadata/mod_expires.la modules/metadata/mod_headers.la modules/metadata/mod_usertrack.la modules/metadata/mod_unique_id.la modules/metadata/mod_setenvif.la modules/ssl/mod_ssl.la modules/test/mod_optional_hook_export.la modules/test/mod_optional_hook_import.la modules/test/mod_optional_fn_import.la modules/test/mod_optional_fn_export.la modules/test/mod_bucketeer.la modules/http/mod_http.la modules/http/mod_mime.la modules/dav/main/mod_dav.la modules/generators/mod_status.la modules/generators/mod_autoindex.la modules/generators/mod_asis.la modules/generators/mod_info.la modules/generators/mod_suexec.la modules/generators/mod_cgi.la modules/generators/mod_cgid.la modules/dav/fs/mod_dav_fs.la modules/mappers/mod_vhost_alias.la modules/mappers/mod_negotiation.la modules/mappers/mod_dir.la modules/mappers/mod_imap.la modules/mappers/mod_actions.la modules/mappers/mod_speling.la modules/mappers/mod_userdir.la modules/mappers/mod_alias.la modules/mappers/mod_rewrite.la modules/mappers/mod_so.la server/mpm/prefork/libprefork.la server/libmain.la os/unix/libos.la -lz -lssl -lcrypto /Users/wiz/Desktop/httpd-2.0.50/srclib/pcre/libpcre.la /Users/wiz/Desktop/httpd-2.0.50/srclib/apr-util/libaprutil-0.la -lgdbm -ldb-4.1 /Users/wiz/Desktop/httpd-2.0.50/srclib/apr-util/xml/expat/lib/libexpat.la -liconv /Users/wiz/Desktop/httpd-2.0.50/srclib/apr/libapr-0.la -lpthread
```


```
ld: warning multiple definitions of symbol _regcomp
/Users/wiz/Desktop/httpd-2.0.50/srclib/pcre/.libs/libpcre.al(pcreposix.lo) definition of _regcomp in section (__TEXT,__text)
/usr/lib/libpthread.dylib(regcomp.So) definition of _regcomp
ld: warning multiple definitions of symbol _regexec
/Users/wiz/Desktop/httpd-2.0.50/srclib/pcre/.libs/libpcre.al(pcreposix.lo) definition of _regexec in section (__TEXT,__text)
/usr/lib/libpthread.dylib(regexec.So) definition of _regexec
ld: warning multiple definitions of symbol _regfree
/Users/wiz/Desktop/httpd-2.0.50/srclib/pcre/.libs/libpcre.al(pcreposix.lo) definition of _regfree in section (__TEXT,__text)
/usr/lib/libpthread.dylib(regfree.So) definition of _regfree
ld: Undefined symbols:
_apr_procattr_child_errfn_set
_apr_procattr_error_check_set
_apr_os_pipe_put_ex
_apr_table_compress
_apr_bucket_alloc_create_ex
_apr_env_delete
_apr_env_get
_apr_env_set
_apr_file_mtime_set
_apr_filepath_list_merge
_apr_filepath_list_split
_apr_proc_mutex_lockfile
_apr_proc_other_child_alert
_apr_proc_other_child_refresh
_apr_proc_other_child_refresh_all
_apr_socket_atmark
_apr_temp_dir_get
make[1]: *** [httpd] Error 1
make: *** [all-recursive] Error 1
```


----------



## michaelsanford (Jul 14, 2004)

My best suggestion is *sudo fink install apache2*


----------



## wiz (Jul 15, 2004)

hmm maybe.. but i was compiling it for the fun of it actually heh. so i don't care if it works or not. but if i could get it to work that would be great


----------



## michaelsanford (Jul 16, 2004)

What was the ./configure string you used? I don't know anything about the way you compiled it...I compiled httpd2 several times with a bunch of options and never had any problems.


----------



## wiz (Jul 17, 2004)

heh i tried to max out all options as far as possible


```
./configure --sysconfdir=/etc --enable-v4-mapped --enable-auth-digest --enable-auth-dbm --enable-file-cache --enable-charset-lite --enable-cache --enable-disk-cache --enable-mem-cache --enable-case-filter --enable-case-filter-in --enable-ext-filter --enable-deflate --enable-logio --enable-mime-magic --enable-cern-meta --enable-expires --enable-headers --enable-usertrack --enable-unique-id --enable-ssl --enable-optional-hook-export --enable-optional-hook-import --enable-optional-fn-import --enable-optional-fn-export --enable-bucketeer --enable-static-support --enable-http --enable-dav --enable-info --enable-cgi --enable-cgid --enable-dav-fs --enable-vhost-alias --enable-rewrite --enable-so --enable-speling --enable-suexec
```


----------



## michaelsanford (Jul 18, 2004)

Ahh yes so you did.

If I were you I'd try reconfiguring it with just, say, the following modules: speling, vhost-alias, headers, expires, unique-id

And see what happens.

PS may be a silly question but do you issue all your commands as root (sudo/su)?


----------



## wiz (Jul 18, 2004)

no only "make install"


----------



## michaelsanford (Jul 18, 2004)

If you're installing apache to a folder that is owned by root you'll need root privilages to put the files there...

Whenever I build anything I always do sudo ./configure ; sudo make build ; sudo make install;


----------



## wiz (Jul 18, 2004)

hmm i find that risky actually or maybe i'm just very paranoid.. i simply move the folder to desktop.. then ./configure, make and (make test at times) then sudo make install. as far as possible i refrain from sudo or su, anything root actually.


----------



## michaelsanford (Jul 19, 2004)

To be honest, yes you're paranoid  j/k

If you download and verify (with MD5 or GPG/PGP signatures) and it's from a reputable mirror (like apache.org for example) you can be relatively sure the app won't do anything malicious.


----------

