pagination: Only one result is shown even if there are more than one?

Lets clean this up:

<h2>
 <?php $num = $wp_query->post_count; if (have_posts()) :?>
 <a href="https://wordpress.stackexchange.com/questions/190595/<?php the_permalink(); ?>"><?php the_title();?></a> 
<?php endif;?> 
 <?php $search_count = 0; $search = new WP_Query("s=$s & showposts=5"); if($search->have_posts()) : while($search->have_posts()) : $search->the_post(); $search_count++; endwhile;    else : ?>
 <?php next_posts_link(); ?>
<?php previous_posts_link(); ?>
        <p> there were no results </p> <?php endif;?>  </h2>

Lets indent the code, place each statement on its own line, and remove the <?php tag spam:

<h2><?php
$num = $wp_query->post_count;
if (have_posts()) :
    ?> <a href="https://wordpress.stackexchange.com/questions/190595/<?php the_permalink(); ?>"><?php the_title();?></a><?php
endif;
$search_count = 0;
$search = new WP_Query("s=$s & showposts=5");
if($search->have_posts()) :
    while($search->have_posts()) :
        $search->the_post();
        $search_count++;
    endwhile;
else :
    next_posts_link();
    previous_posts_link();
    ?><p> there were no results </p><?php
endif;
?>
</h2>

Now lets add comments for everything wrong with this code:

<h2><?php
$num = $wp_query->post_count; // This line is pointless, $num is never used, and if it was, it would still fail because $wp_query has just appeared out of nowhere
if (have_posts()) :
    // this is a post loop that doesn't have a loop in it
    ?> <a href="https://wordpress.stackexchange.com/questions/190595/<?php the_permalink(); ?>"><?php the_title();?></a><?php
endif;
$search_count = 0;
$search = new WP_Query("s=$s & showposts=5"); // where does $s come from? There shouldn't be spaces here, if you don't define it, how is the computer supposed to know? It doesn't magically know these things
if($search->have_posts()) :// this loop is completely unnecessary, you could do $search->post_count
    while($search->have_posts()) :
        $search->the_post();
        $search_count++; 
    endwhile;
else :
    // but this is for if there were no results for your search, which will always be the case because the $s variable doesn't exist
    next_posts_link();
    previous_posts_link();
    ?><p> there were no results </p><?php // a p tag is an inline element, you can't put it inside another inline element like a h2, it has to go inside a block element like a div, this will fail validation and have styling issues
endif;
?>
</h2>

Going back to your question, lets focus here:

if (have_posts()) :
    // this is a post loop that doesn't have a loop in it
    ?> <a href="https://wordpress.stackexchange.com/questions/190595/<?php the_permalink(); ?>"><?php the_title();?></a><?php
endif;

This is what a standard post loop looks like:

if ( have_posts() ) { // did we find posts?
    while( have_posts() ){ // while we still have posts
        the_post(); // set the current post
        the_title(); // do stuff with the current post
    }
} else {
    // we didn't find any posts
}

Because you don’t have a loop, it can’t loop through all the posts, instead it only gets the chance to do 1

It may be that you are seeing the post from your first broken post loop, and assuming it’s coming from the second query loop you made. In which case, your use of the $s variable is the problem. $s doesn’t exist until you use it, kind of like asking someone to read a book that hasn’t been written yet.