You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by nk...@gmx.de on 2004/05/27 15:52:43 UTC

Can't link SVN libraries in Visual Studio

MSVC .NET 2003

Hi,

I've tested the Win32 libs 1.0.3 and 1.0.4. While linking the prebuilt SVN
libs to my MSVC .NET 2003 project the linker error came up:
"apr.lib(rand.obj): error LNK2019: unresolved external symbol
__imp__UuidCreate@4 referenced in function _apr_os_uuid_get@4".
What's going wrong?
I believe I have all the necessary SVN libs included.

Best regards
N. Kowalsky

-- 
"Sie haben neue Mails!" - Die GMX Toolbar informiert Sie beim Surfen!
Jetzt aktivieren unter http://www.gmx.net/info


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Help. The API docs are fragmentlike, incoherent and confusing.

Posted by kf...@collab.net.
nkowalsky@gmx.de writes:
> MSVC .NET 2003
> Subversion 1.0.3/1.0.4
> 
> Hi,
> 
> I have massive problems using the Subversion API. 

Since you don't list the exact documents you've read, it's hard for
anyone to know how to help you further.

I'd suggest the HACKING file (which explains the pool concept in
detail), but that seems so obvious that I assume you've been there
already.

The "main doc" to which you refer is a book intended for users, not
developers.  It is not an API doc, any more than a car's user manual
tells one how to replace the transmission.

If you just want to access a local repository without user management,
why not use the file:// access method already built into svn?

-Karl


> There are only fragmentlike docs for the API I've found:
> I've studied the main doc by Ben Collins-Sussman, Brian W. Fitzpatrick, C.
> Michael Pilato. But the main point is focused on common users.
> Then I've read Garrett Rooney's Using the SVN API.
> The hint to read the source code of the SVN client source codes is
> well-meant. The sources are too complicated and disturbing.
> The docs lack coherence and are totally confusing, e.g. pool concept,
> authorizing.
> I couldn't found any coherent examples for the API beginner.
> 
> I want only use a simple repository on a drive without password protection
> and user administration. 
> I gleaned from the various sources a fragmented basic understanding and
> wrote following program:
> creating a repository, checkout and add a file (test.txt).
> While adding the file the API crashes the program.
> 
> code snippet:
> 
> 
> svn_error_t* error;
> 
> apr_pool_t* createPool = svn_pool_create(NULL);
> svn_repos_t* repos;
> error = svn_repos_create(&repos, "c:/temp/repos", NULL, NULL, NULL, NULL,
> createPool);
> 
> apr_pool_t* ctxPool = svn_pool_create(NULL);
> svn_client_ctx_t* ctx;
> error = svn_client_create_context(&ctx, ctxPool);
> 
> apr_pool_t* providerArrayPool = svn_pool_create(NULL);
> apr_array_header_t *providers = apr_array_make (providerArrayPool, 1, sizeof
> (svn_auth_provider_object_t *));
> 
> apr_pool_t* providerPool = svn_pool_create(NULL);
> svn_auth_provider_object_t* provider;
> svn_client_get_simple_provider(&provider, providerPool);
> *(svn_auth_provider_object_t **)apr_array_push (providers) = provider;
> 
> apr_pool_t* batonPool = svn_pool_create(NULL);
> svn_auth_baton_t *auth_baton;
> svn_auth_open (&auth_baton, providers, batonPool);
> ctx->auth_baton = auth_baton;
> 
> apr_pool_t* checkoutPool = svn_pool_create(NULL);
> svn_revnum_t rev;
> svn_opt_revision_t revision;
> revision.kind = svn_opt_revision_head;
> error = svn_client_checkout(&rev, "file:///c:/temp/repos",
> "c:/temp/workcopy", &revision, true, ctx, checkoutPool);
> 
> apr_pool_t* addPool = svn_pool_create(NULL);
> error = svn_client_add("c:/temp/workcopy/test.txt", false, ctx, addPool);
> 
> 
> Thank you.
> 
> Best regards
> N. Kowalsky
> 
> -- 
> "Sie haben neue Mails!" - Die GMX Toolbar informiert Sie beim Surfen!
> Jetzt aktivieren unter http://www.gmx.net/info
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

RE: Help. The API docs are fragmentlike, incoherent and confusing.

Posted by Arild Fines <ar...@broadpark.no>.
nkowalsky@gmx.de wrote:
> MSVC .NET 2003
> Subversion 1.0.3/1.0.4
>
> Hi,
>
> I have massive problems using the Subversion API.
>
> There are only fragmentlike docs for the API I've found:
> I've studied the main doc by Ben Collins-Sussman, Brian W. Fitzpatrick, C.
> Michael Pilato. But the main point is focused on common users.

Have you seen the doxygen-generated documentation? It can be found at
http://svn.collab.net/svn-doxygen/

You can also generate it yourself from the source tree using the doxygen
tool. In my work with Ankh, I've found that these docs plus the source to
the svn executable is pretty much all you need.


--
Arild

AnkhSVN: http://ankhsvn.tigris.org
Blog: http://ankhsvn.com/blog
IRC: irc://irc.freenode.net/ankhsvn

"Weaseling out of things is good. It's what separates us from the other
animals....except weasels." -- Homer Simpson


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Help. The API docs are fragmentlike, incoherent and confusing.

Posted by nk...@gmx.de.
MSVC .NET 2003
Subversion 1.0.3/1.0.4

Hi,

I have massive problems using the Subversion API. 

There are only fragmentlike docs for the API I've found:
I've studied the main doc by Ben Collins-Sussman, Brian W. Fitzpatrick, C.
Michael Pilato. But the main point is focused on common users.
Then I've read Garrett Rooney's Using the SVN API.
The hint to read the source code of the SVN client source codes is
well-meant. The sources are too complicated and disturbing.
The docs lack coherence and are totally confusing, e.g. pool concept,
authorizing.
I couldn't found any coherent examples for the API beginner.

I want only use a simple repository on a drive without password protection
and user administration. 
I gleaned from the various sources a fragmented basic understanding and
wrote following program:
creating a repository, checkout and add a file (test.txt).
While adding the file the API crashes the program.

code snippet:


svn_error_t* error;

apr_pool_t* createPool = svn_pool_create(NULL);
svn_repos_t* repos;
error = svn_repos_create(&repos, "c:/temp/repos", NULL, NULL, NULL, NULL,
createPool);

apr_pool_t* ctxPool = svn_pool_create(NULL);
svn_client_ctx_t* ctx;
error = svn_client_create_context(&ctx, ctxPool);

apr_pool_t* providerArrayPool = svn_pool_create(NULL);
apr_array_header_t *providers = apr_array_make (providerArrayPool, 1, sizeof
(svn_auth_provider_object_t *));

apr_pool_t* providerPool = svn_pool_create(NULL);
svn_auth_provider_object_t* provider;
svn_client_get_simple_provider(&provider, providerPool);
*(svn_auth_provider_object_t **)apr_array_push (providers) = provider;

apr_pool_t* batonPool = svn_pool_create(NULL);
svn_auth_baton_t *auth_baton;
svn_auth_open (&auth_baton, providers, batonPool);
ctx->auth_baton = auth_baton;

apr_pool_t* checkoutPool = svn_pool_create(NULL);
svn_revnum_t rev;
svn_opt_revision_t revision;
revision.kind = svn_opt_revision_head;
error = svn_client_checkout(&rev, "file:///c:/temp/repos",
"c:/temp/workcopy", &revision, true, ctx, checkoutPool);

apr_pool_t* addPool = svn_pool_create(NULL);
error = svn_client_add("c:/temp/workcopy/test.txt", false, ctx, addPool);


Thank you.

Best regards
N. Kowalsky

-- 
"Sie haben neue Mails!" - Die GMX Toolbar informiert Sie beim Surfen!
Jetzt aktivieren unter http://www.gmx.net/info


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Can't link SVN libraries in Visual Studio

Posted by Branko Čibej <br...@xbc.nu>.
nkowalsky@gmx.de wrote:

>MSVC .NET 2003
>
>Hi,
>
>I've tested the Win32 libs 1.0.3 and 1.0.4. While linking the prebuilt SVN
>libs to my MSVC .NET 2003 project the linker error came up:
>"apr.lib(rand.obj): error LNK2019: unresolved external symbol
>__imp__UuidCreate@4 referenced in function _apr_os_uuid_get@4".
>What's going wrong?
>I believe I have all the necessary SVN libs included.
>  
>
You're not linking the necessary Windows libraries. UuidCreate is a 
Win32 function.




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org